Numbers
The Ruby Numbers badge will get you comfortable working with numbers in Ruby. This badge teaches you about integers, floating point numbers, math, and more. You'll learn how to create and work with numbers, compare numbers, and work with currency.
7 videos • 1 quiz • 0 code challenges
-
Play
Watch
Creating Numbers
5 minutes 50 seconds
-
Play
Preview
Operators
3 minutes 41 seconds
-
Play
Preview
Comparison
3 minutes 43 seconds
-
Play
Preview
Math
3 minutes 3 seconds
-
Play
Preview
Random Numbers and Formatting
2 minutes 58 seconds
-
Play
Preview
Floating Point Math
2 minutes 50 seconds
-
Play
Preview
Currency
3 minutes 33 seconds
-
ABC
Preview
Quiz: Review
5 questions
Try writing a Ruby program that asks a user to input numbers and then multiplies them together. Have the program print out the result to two decimal places regardless of whether or not the user entered an integer or floating point number.