Q:

Write a C# Sharp program that takes an age (for example 20) as input and prints something as "You look older than 20"

0

Write a C# Sharp program that takes an age (for example 20) as input and prints something as "You look older than 20"

Sample Output:

Enter your age 45                                                                                             
You look younger than 45

All Answers

need an explanation for this answer? contact us directly to get an explanation for this answer

using System;
public class Exercise11
{
  public static void Main()
  {
    int age;
    Console.Write("Enter your age ");
    age = Convert.ToInt32(Console.ReadLine());
    Console.Write("You look younger than {0} ",age);
  }
}

need an explanation for this answer? contact us directly to get an explanation for this answer

total answers (1)

Similar questions


need a help?


find thousands of online teachers now