Advertisement
Guest User

Untitled

a guest
Mar 31st, 2017
103
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.98 KB | None | 0 0
  1. import java.util.*;
  2. import java.lang.*;
  3. import java.io.*;
  4.  
  5. class Main {
  6.  
  7.     public static void main (String[] args) {
  8.         for (int i = 0, count3 = 0, count5 = 0, isNeedSeparator = 0, sosacherZahotelChtobyVivodilosChislo = 1; i < 100; ++i, ++count3, ++count5,
  9.                 System.out.print((count3 == 3 && 0 == (count3 = 0) && 1 == (isNeedSeparator = 1) && 0 == (sosacherZahotelChtobyVivodilosChislo = 0) ?
  10.                             "Fizz"
  11.                             : ((isNeedSeparator == 1 && 0 == (isNeedSeparator = 0)) ?
  12.                                 " "
  13.                                 : ""))
  14.                         + (count5 == 5 && 0 == (count5 = 0) && 0 == (isNeedSeparator = 0) && 0 == (sosacherZahotelChtobyVivodilosChislo = 0)?
  15.                             "Buzz "
  16.                             : "")
  17.                         + ((sosacherZahotelChtobyVivodilosChislo == 0 && 1 == (sosacherZahotelChtobyVivodilosChislo = 1)) ? "" : i + " ")
  18.                 ));
  19.     }
  20. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement