Advertisement
Guest User

Untitled

a guest
Sep 11th, 2019
125
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Scala 0.45 KB | None | 0 0
  1. package universe.solarsystem.earth.animals.human.jobs
  2.  
  3. import java.util.Calendar
  4.  
  5. object Programmer extends App {
  6.   val activity = new Activity(Activity.PROGAMMER)
  7.   val bestDayInYear = 256
  8.   def everyDay() = {
  9.     while (true) {
  10.       activity.work()
  11.       activity.drinkCoffe()
  12.       if (Calendar.getInstance.get(Calendar.DAY_OF_YEAR) == bestDayInYear){
  13.         printf("Happy programmers day!")
  14.       }
  15.       activity.sleep()
  16.     }
  17.   }
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement