Hacker Newsnew | past | comments | ask | show | jobs | submit | Architrixs's commentslogin

great game, tho it feels a little slow to interact.. are interactions made slow purposely? i feel fast and rapid mode will be good for this


Are you referring to the interruptions from one question to the next that show the explanation? Those were added on purpose because originally I had this in mind for kids in the 8 -- 16 years old range and wanted it to be educational.

But I see what you mean, and it's no trouble to add an option for "rapid mode" to just blaze through questions! I'll add this to the list!


do we need a NSFW flair here on hn as well..


Can’t believe I whipped up this web app in just 15 minutes using Cursor!


Thank You for letting me know about BOFH, I'm going to read those stories now, Seems fun!!


We are a small team of new software developer. Just a member, and as such there's no definite roles.

This war-game sounds pretty neat.


No.. it's not all hands on deck event... I was planning on doing these maybe one component/module per team per week, I have made guidelines and some general good practices that would reward points. This would be more of a passive activity for the members, my team and I are new to software development as well so I was hoping this would be good for learning as well


Just wanted to add... C# being strongly typed language, some times can be a pain. Just spent an hour trying to parse a JSON String; changing its parts and again de-serializing it... working with JObject, JToken, etc..so on; Though i'm just getting familiar with it.


This is where the C# `dynamic` keyword sometimes shines. It's a lesser known feature from a project called the DLR that tried to shake up the CLR to better support more languages like IronPython and IronRuby. Both IronPython and IronRuby kind of got scrapped/pushed aside, and the DLR never quite got the love it deserved, but what remains is still sometimes useful. If you are still using JSON.NET (Newtonsoft.JSON) (which you did mention its JSON LINQ JObject/JToken, etc.), it still supports the `dynamic` operator for working with JSON "more naturally":

  dynamic jsonObject = JObject.Parse(someJsonString);
  jsonObject.some.deep[1].propertyName = "Updated string";
  return jsonObject.ToString(); // re-serialize the updated JSON
You don't get much IntelliSense when using dynamic, but it makes it much easier to write what you want/expect to write with a JSON object than if you were navigating the JSON LINQ (JObject/JToken/etc) objects by hand.

The documentation still includes pages on dynamic, even though dynamic has become a mostly forgotten feature and there are still developers that would never use dynamic. For example: https://www.newtonsoft.com/json/help/html/QueryJsonDynamic.h...

I appreciate that dynamic exists in C#. I've done some wild things with dynamic over the years. It sometimes makes me sad how under-appreciated a tool it can be.

ETA: Obviously dynamic is not type-safe, it's a great escape hatch from type safety for small cases where "just do what I want" is nicer/more natural than type safety. As the sibling comment points out, if you still prefer type safety there are type deserializers that can be easier to use. These days with records in C# 9+ writing quick types to deserialize to is even relatively painless.


You should be able to simply use Json.Deserialize<T>() ?

The beauty of types in this case is that the JSON structure has a natural way to be expressed in C#… we just need to utilize it

Or a JsonNode if you don’t know the structure


If you are using VS try the JSON to Class converter that's built in.

https://www.howtosolutions.net/2020/07/visual-studio-creatin...


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: