static void Main(string[] args) { Sharpie haha = new Sharpie("red", 3.0f); haha.use(); Console.WriteLine("{0}{1}{2}", haha.Color, haha.Width, haha.InkAmount); }
static void Main(string[] args) { Sharpie royal = new Sharpie("navy", 1f); Sharpie gold = new Sharpie("gold", 2f); /* draw Swedish flag * * rrr gg rrrrr * rrr gg rrrrr * gggggggggggg * rrr gg rrrrr * rrr gg rrrrr * */ for (int i = 1; i <= 32; i++) { royal.Use(); } for (int i = 1; i <= 10; i++) { gold.Use(); } Console.WriteLine($"After drawing the Swedish flag, we have {royal.GetInkStatus()}% of our royal blue sharpie, and {gold.GetInkStatus()}% of our golden yellow sharpie left."); Console.ReadLine(); }
static void Main(string[] args) { var sharpie = new Sharpie("Red", 14); Console.WriteLine(sharpie); Console.ReadLine(); }
static void Main(string[] args) { Sharpie bob = new Sharpie("violet", 10); bob.Use(); Console.Read(); }
static void Main(string[] args) { Sharpie sharpieOne = new Sharpie("Green", 15.3f); sharpieOne.Use(); sharpieOne.Use(); Console.WriteLine(sharpieOne.GetInkAmount); }
static void Main(string[] args) { Sharpie Fart = new Sharpie("Fosszinu", 15); Fart.use(); Console.WriteLine("asd {0} megalol", Fart.Ink); Console.ReadKey(); }
static void Main(string[] args) { var sharpie = new Sharpie("red", 3.44f); sharpie.Use(); sharpie.Use(); Console.ReadLine(); }
public static void Main(string[] args) { Sharpie greenSharpie = new Sharpie("green", 2); greenSharpie.Use(); Console.WriteLine(greenSharpie.inkamount); }
//Create Sharpie class //We should know about each sharpie their Color(which should be a string), Width(which will be a floating point number), InkAmount(another floating point number) //When creating one, we need to specify the Color and the Width //Every sharpie is created with a default 100 as InkAmount //We can Use() the sharpie objects //which decreases inkAmount static void Main(string[] args) { var mySharpie = new Sharpie("Blue", 10); mySharpie.Use(); Console.WriteLine(mySharpie.Inkamount); }
static void Main(string[] args) { Sharpie sharpie = new Sharpie("green", 34.23f); sharpie.Use(); Console.WriteLine(sharpie.color + " " + sharpie.inkAmount + " " + sharpie.width); Console.ReadLine(); }
static void Main(string[] args) { Sharpie newSharpie = new Sharpie("Red", 5); newSharpie.Use(); newSharpie.Use(); Console.ReadLine(); }
static void Main(string[] args) { Sharpie Matey = new Sharpie("white", 0.5f); Sharpie Lola = new Sharpie(100); Matey.Use(11); Lola.Use(21); Console.WriteLine("Lola is " + Lola.color + " it is " + Lola.width + " big, and the ink amount is " + Lola.inkAmount); Console.WriteLine("Matey is " + Matey.color + " it is " + Matey.width + "big and it's ink amount is " + Matey.inkAmount); Console.ReadLine(); }
static void Main(string[] args) { Sharpie sharpieOne = new Sharpie("Red", 5f); for (int i = 0; i < 5; i++) { sharpieOne.Use(); } Console.WriteLine($"{sharpieOne.inkAmount}% of the ink available"); Console.ReadLine(); }
static void Main(string[] args) { var varazsCeruza = new Sharpie("mindenféle", 10); while (varazsCeruza.inkAmount > 0) { varazsCeruza.Use(); } Console.WriteLine("..."); Console.Read(); }
static void Main(string[] args) { Sharpie numberOne = new Sharpie("Blue", 200); for (int i = 0; i < 30; i++) { numberOne.Use(); } Console.WriteLine(numberOne.NumberOfUsesLeft()); Console.ReadLine(); }
static void Main(string[] args) { Sharpie firstSharpie = new Sharpie("orange", 13); Sharpie secondSharpie = new Sharpie("blue", 41); firstSharpie.Use(); secondSharpie.Use(); Console.WriteLine("the level of ink is: " + firstSharpie.inkAmount); Console.WriteLine("the level of ink is: " + secondSharpie.inkAmount); Console.ReadLine(); }
static void Main(string[] args) { Sharpie Capeti = new Sharpie("blue", 100); Capeti.Use(); Capeti.Use(); Capeti.Use(); Capeti.Use(); Capeti.Use(); Capeti.Use(); Console.ReadLine(); }
static void Main(string[] args) { /*Sharpie * Create Sharpie class * We should know about each sharpie their Color (which should be a string), Width (which will be a floating point number), InkAmount (another floating point number) * When creating one, we need to specify the Color and the Width * Every sharpie is created with a default 100 as InkAmount * We can Use() the sharpie objects * which decreases inkAmount*/ Sharpie PinkSharpie = new Sharpie("pink", 2); PinkSharpie.Use(); Console.ReadLine(); }
static void Main(string[] args) { //Create Sharpie class //We should know about each sharpie their Color(which should be a string), Width(which will be a floating point number), InkAmount(another floating point number) //When creating one, we need to specify the Color and the Width //Every sharpie is created with a default 100 as InkAmount //We can Use() the sharpie objects //which decreases inkAmount Sharpie s1 = new Sharpie("black", 5); Sharpie s2 = new Sharpie("blue", 10); Console.WriteLine(s1.Use()); Console.ReadLine(); }
static void Main(string[] args) { Sharpie sharpie1 = new Sharpie(); sharpie1.SayHi(); }