Guest User

Untitled

a guest
Oct 8th, 2020
29
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Jos:
  2. day = 3
  3. project.getKey() antaa 'XXXX'
  4. hourOfDay = 16
  5.  
  6. niin mitä allaoleva antaa, nollan vai ykkösen? :)
  7.  
  8. *****
  9.  
  10. if (day == 6 || day == 7)if (day == 6 || day == 7) return (double)0;
  11.  
  12. if (project.getKey() == 'XXXX') {
  13. if (hourOfDay < 7 || hourOfDay >= 15) {
  14. return (double)0;
  15. }
  16. else {
  17. return (double)1;
  18. }
  19. }
  20. else {
  21. if (hourOfDay < 8 || hourOfDay >= 18) {
  22. return (double)0; }
  23. else {
  24. return (double)1;
  25. }
  26. }
RAW Paste Data