Hacker News new | ask | show | jobs
by SeasonalEnnui 901 days ago
I have seen a few comments expressing a desire for a statically typed scripting language. I’ve been using a new workflow for a couple of years I’d like to share.

Install .NET 8, and create a new C# Console application. From .NET 6 onwards, it uses the new “top level statements” style which is effectively like the blank slate of a script file. The barrier to entry has never been lower. (https://learn.microsoft.com/en-us/dotnet/core/tutorials/top-...)

This lets you take advantage of a really healthy toolchain/package manager ecosystem.

You can take this a step further by using VS Code with the Polyglot Notebooks extension to get a Jupyter-style experience with C# code. (https://marketplace.visualstudio.com/items?itemName=ms-dotne...)