What is a difference between .cs file and class?

Experience Level: Junior
Tags: C#


  • The C# source code contains classes (except the other code structures).
  • The C# source code is stored in files with .cs extension.
  • So the file with .cs extension contains C# classes (most of the time).
Related C# job interview questions
C# for beginners
C# for beginners

Are you learning C#? Try our test we designed to help you progress faster.

Test yourself