Vapio

task4

Mar 3rd, 2021 (edited)
761
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. using System;
  2.                    
  3. public class Program
  4. {
  5.     public static void Main()
  6.     {
  7.         uint waitTimePerPeople = 10;
  8.         uint minutesInHour = 60;
  9.  
  10.         uint peopleAmount = 0;
  11.         uint waitTime = 0;
  12.         uint minutesWaitTime = 0;
  13.         uint hoursWaitTime = 0;
  14.        
  15.         Console.WriteLine("Please input amount of people : ");
  16.         peopleAmount = Convert.ToUInt32(Console.ReadLine());
  17.        
  18.         waitTime = peopleAmount * waitTimePerPeople;
  19.         hoursWaitTime = waitTime / minutesInHour;
  20.         minutesWaitTime = waitTime % minutesInHour;
  21.        
  22.         string waitTimeString = String.Format("Your waiting time is {0} hours {1} minutes ", hoursWaitTime, minutesWaitTime);      
  23.        
  24.         Console.WriteLine(waitTimeString);
  25.     }
  26. }
RAW Paste Data

Adblocker detected! Please consider disabling it...

We've detected AdBlock Plus or some other adblocking software preventing Pastebin.com from fully loading.

We don't have any obnoxious sound, or popup ads, we actively block these annoying types of ads!

Please add Pastebin.com to your ad blocker whitelist or disable your adblocking software.

×