Advertisement
Stanislav2812

Untitled

Aug 18th, 2017
57
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.53 KB | None | 0 0
  1. using System;
  2. using System.Threading;
  3. using System.Collections;
  4. using System.Collections.Generic;
  5. using System.Linq;
  6. using System.Text;
  7. using System.Threading.Tasks;
  8.  
  9. namespace MyFirstProgram
  10. {
  11.     class Program
  12.     {
  13.  
  14.         static void Main(string[] args)
  15.         {
  16.  
  17.             Console.WriteLine(convertion(2, 2));
  18.            
  19.         }
  20.  
  21.  
  22.  
  23.         public static int convertion(int a, int b)
  24.         {
  25.             if(a == b)
  26.             {
  27.                 a = a * -1;
  28.             }
  29.  
  30.             return a;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement