using System;
class line
{
Public class point // What is the reason why public should be included in this part?
{
public int x;
}
public point starting = new point();
}
class C_sharp_book
{
public static void Main()
{
line mine = new line();
mine.starting.x = 3;
Console.WriteLine("{0}", mine.starting.x);
}
}
I've put a question on the comment!
c#
mine.starting.x = 3; This direct access to class member variables requires a public declaration. If you do not declare it public, you must approach it indirectly through the function.
930 When building Fast API+Uvicorn environment with PyInstaller, console=False results in an error
578 Who developed the "avformat-59.dll" that comes with FFmpeg?
586 PHP ssh2_scp_send fails to send files as intended
575 rails db:create error: Could not find mysql2-0.5.4 in any of the sources
625 GDB gets version error when attempting to debug with the Presense SDK (IDE)
© 2024 OneMinuteCode. All rights reserved.