Python foo & bar

""" Write a code which displays number from 1 to 199. For every mutliples of 3, display "Foo" instead of the number and for the multiples of 5 display "Bar". For numbers multiples of 3 and 5, display "Foo Bar". Example output: 1 2 Foo 4 Bar Foo 7 8 Foo Bar 11 Foo 13 14 Foo Bar ... """ for x in range(1, 199): print(x)

Be the first to comment

You can use [html][/html], [css][/css], [php][/php] and more to embed the code. Urls are automatically hyperlinked. Line breaks and paragraphs are automatically generated.