Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading;
- using System.Threading.Tasks;
- namespace Bottles
- {
- class Program
- {
- static void Main(string[] args)
- {
- double containerVolume = 100; // in lithers
- int counter = 100;
- do {
- Console.WriteLine("We are moving the bottle");
- Thread.Sleep(1000);
- Console.WriteLine("We are filling the bottle!");
- Thread.Sleep(2000);
- Console.WriteLine("The bottle is full!");
- Console.WriteLine("----------- New cycle! -----------");
- containerVolume -= 10.5;
- if (containerVolume <= 0) {
- Console.WriteLine("we are filling the container :)");
- containerVolume = 100;
- Thread.Sleep(20000);
- }
- } while(true);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement