Skip to Content

C# - What is DataType used for?

Table of contents

No titles in the blog post

Question:

C# – What is DataType used for? I don’t understand the concept of how to apply it correctly, I googled enough

Answer:

C#, similar to C++ and Java is a strongly typed language. In a strongly typed language, we must provide a variable type to indicate what type of data we are going to store. For Ex: integer, money, text, float etc.

Ex:
int myCounter = 0;
string firstname = “First”;