How to create a 2D point data structure with two floating-point numbers in VB.NET

1 Answer

0 votes
Imports System

Public Class Program
    Structure Point
        Public x As Double
        Public y As Double
    End Structure

    Public Shared Sub Main()
        Dim p As Point

        p.x = 2.36
        p.y = 1.94

        Console.Write(p.x & " " & p.y)
    End Sub
End Class




' run:
'
' 2.36 1.94
'

 



answered Dec 26, 2022 by avibootz
...