I'm primarily a Python/R developer. In those languages, the way I develop is to sketch out a data and class structure, write the methods and their tests in interactive mode, then refactor them up into class methods and properties and sort out the tests. Some friends are suggesting I learn C#. I don't do much work with complied/staticly typed languages.Can I develop in an 'interactive mode' the same way in C# - that is, load in some sample data, write methods interactively to ensure they're working right, then push methods up to classes as they're completed? Or is this not a natural way to develop in a compiled language?
Can you do iterative development in c#?
c#;python;r
Can I develop in an 'interactive mode' the same way in C# - that is, load in some sample data, write methods interactively to ensure they're working right, then push methods up to classes as they're completed?Not the same way. There isn't really such interactive tools for C# since the problems you're usually solving are large enough to make that unweildy (and the standard compilation model doesn't lend itself to it).Or is this not a natural way to develop in a compiled language?Every language has its quirks and idioms. I can't write C# code like I do C++, and I can't write JavaScript the same way as perl. You're going to need to adapt when learning a new language, and that sort of adaptation is the main benefit of learning different languages - you get a broader perspective of different ways of doing things.All that said, you can and should do iterative development in C#. Smaller chunks of code are easier to reason about, easier to test, easier to debug. The mechanics of doing that though are likely to change due to the quirks of the language and the tools available.