Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //Disclaimer: The creator of 'C# Shell (C# Offline Compiler)' is in no way responsible for the code posted by any user.
- using System;
- using System.IO;
- using System.Linq;
- using System.Collections.Generic;
- namespace CSharp_Shell
- {
- public static class Program
- {
- public static void Main()
- {
- int a = int.Parse(Console.ReadLine());
- int b= int.Parse(Console.ReadLine());
- int c = int.Parse(Console.ReadLine());
- if(a==b&&a==c&&c==a)
- {
- Num(b,c);
- Console.Write($"\n{a}\n{b}\n{c}");
- return;
- }
- if(a>=b && a>= c && b>=c)
- {
- Console.Write($"\n{a} \n{b} \n{c}");
- }
- else if(a>=b && a>=c && c>=b)
- {
- Console.Write($"\n{a} \n{c} \n{b}");
- }
- if(b>=a && b>=a && a>=c)
- {
- Console.Write($"\n{b}\n{a}\n{c}");
- }
- else if(b>=a && b>=c && c>=a)
- {
- Console.Write($"\n{b}\n{c}\n{a}");
- }
- if(c>=a && c>=b && a>=b)
- {
- Console.Write($"\n{c}\n{a}\n{b}");
- }
- else if(c>=a && c>=b && b>=a)
- {
- Console.Write($"\n{c}\n{b}\n{a}");
- }
- }
- private static int Num( int b, int c)
- {
- if(b>=c)
- {
- return b;
- }
- else
- {
- return c;
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement