Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //Business.cs
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace Oef1p24Hello
- {
- class Business
- {
- private string naam;
- public string maakHallo(string pnaam)
- {
- return "Hello " + pnaam;
- }
- public string Naam
- {
- get { return naam; }
- set { naam = value; }
- }
- }
- }
- //Program.cs
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace Oef1p24Hello
- {
- class Program
- {
- static void Main(string[] args)
- {
- Business rekenen = new Business();
- Console.WriteLine("Wat is de naam?");
- rekenen.Naam = Console.ReadLine();
- Console.ForegroundColor = ConsoleColor.Green;
- Console.WriteLine("Hallo, " + rekenen.Naam);
- Console.ReadLine();
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment