Getting Numbers
Part of the Fundamentals section of Coddy's C# journey — lesson 38 of 69.
Challenge
BeginnerAdd to the code to get two numbers from the user and store them in variables named num1 and num2 (of double type). After getting the numbers, print them.
The read multiple inputs use:
double num1 = double.Parse(Console.ReadLine());
double num2 = double.Parse(Console.ReadLine());Try it yourself
using System;
public class Program {
public static void Main(string[] args) {
}
}All lessons in Fundamentals
4Operators Part 1
Arithmetic OperatorsModulo OperatorIncrement/DecrementPost Increment/DecrementArithmetic Shortcuts5Operators Part 2
Comparison OperatorsLogical Operators Part 1Logical Operators Part 2Recap - Simple LogicLogical Operators Part 3