Answers for "c# get 2 integers in one line"

C#
1

read in multiple numbers c#

//Read line, and split it by whitespace into an array of strings
string[] tokens = Console.ReadLine().Split();

//Parse element 0
int a = int.Parse(tokens[0]);

//Parse element 1
int b = int.Parse(tokens[1]);
Posted by: Guest on January-16-2020

Code answers related to "c# get 2 integers in one line"

C# Answers by Framework

Browse Popular Code Answers by Language