Yes, but we have to choose the main methods while doing compilation.
csc Hello.cs /main:Demo
csc Hello.cs /main:test