Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- namespace ConsoleApplication1
- {
- class Program
- {
- static void Main(string[] args)
- {
- string vastaus;
- int luku1;
- int luku2;
- Console.WriteLine("Anna 1. luku: ");
- luku1 = int.Parse(Console.ReadLine());
- Console.WriteLine("Anna 2. luku: ");
- luku2 = int.Parse(Console.ReadLine());
- vastaus = "";
- if (luku1 < luku2)
- {
- vastaus = ("pienempi kuin");
- }
- else if (luku1 > luku2)
- {
- vastaus = ("suurempi kuin");
- }
- else if (luku1 == luku2)
- {
- vastaus = ("yhtäsuuri kuin");
- }
- Console.WriteLine("Ensimmäinen luku on {0} toinen luku ", vastaus);
- Console.ReadLine();
- }
- }
- }
Add Comment
Please, Sign In to add comment