Command Line Argument

You might also like

Download as txt, pdf, or txt
Download as txt, pdf, or txt
You are on page 1of 1

d) Write an application that uses two command-line arguments to place values into

a
string and an integer variable, respectively. Then display these values.
Ans:-
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace ConsoleApplication1
{
class Program
{
static void Main(string[] args)
{

string s1 = "TY_IT"; int a = 10;


Console.WriteLine("String=" + s1);
Console.WriteLine("Number=" + a);

Console.WriteLine();

Console.ReadLine();
}
}
}

You might also like