Advertisement
KodingKid

Public Modifiers in C#

Mar 23rd, 2021
124
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.19 KB | None | 0 0
  1. class Humanoid
  2. {
  3.   public string model = "Player1";
  4. }
  5. class Program
  6. {
  7.   static void Main(string[] args)
  8.   {
  9.     Humanoid myObj = new Humanoid();
  10.     Console.WriteLine(myObj.model);
  11.   }
  12. }
  13.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement