Skip to content

Repositório com os códigos gerados no dojo do dia 19/05/2018

Notifications You must be signed in to change notification settings

Grupy-GO/dojo_19_05_2018

Repository files navigation

Dojo do dia 19/05/2018

Balancear expressão com parêntesis, colchetes e chaves

Write a program to determine if the the parentheses (),
the brackets \[\], and the braces {}, in a string are balanced.

For example:
{{)(}} is not balanced because ) comes before (
({)} is not balanced because ) is not balanced between {}
and similarly the { is not balanced between ()
\[({})\] is balanced
{}(\[\]) is balanced
{()}\[\[{}\]\] is balanced

Ano bissexto

Write a function that returns true or false depending on 
whether its input integer is a leap year or not.

A leap year is defined as one that is divisible by 4,
but is not otherwise divisible by 100 unless it is
also divisible by 400.

For example, 2001 is a typical common year and 1996
is a typical leap year, whereas 1900 is an atypical
common year and 2000 is an atypical leap year.

FizzBuzz

Write a program that prints the numbers from 1 to 100.
But for multiples of three print "Fizz" instead of the
number and for the multiples of five print "Buzz". For
numbers which are multiples of both three and five
print "FizzBuzz".

Sample output:
1, 2, Fizz, 4, Buzz, Fizz, 7, 8, Fizz, Buzz, 11, Fizz, 13, 14, FizzBuzz

About

Repositório com os códigos gerados no dojo do dia 19/05/2018

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages