1. To be alone is FAR better than to be in bad company. And the world is full of bad company. Thousands of people are craving to be alone for this reason.
2. You need to be a nice companion to yourself. If you arrive at this level, when you meet other people, you will be eager to share this amazing companion with others, instead of appearing to be begging not to "be alone".
And one piece of advice:
1. If you are a Christian, it is a great time to learn and enjoy God's company through prayer; you will never be alone again.
I understand what the author says, but in my experience, "Nullable Types" and "Open/Sealed Classes" are two different subjects and...
1) For "Nullable Types", I see that it is VERY good to think about if some type can be null or not, or use a type system that does not allow nulls, so you need some "unit" type, and appropriately handle these scenarios. I think it is ok the language enforces this, it really, really helps you to avoid bugs and errors sooner.
2) For "Open/Sealed Classes", my experience says you never (or very rarely) know that a class will need to be extended later. I work with older systems. See, I don't care if you, the original coder, marked this class as "sealed", and it does not matter if you wrote tons of unit tests (like the author advocates), my customer wants (or needs) that I extend that class, so I will need to do a lot of language hacks to do it because you marked as sealed. So, IMHO, marking a class as "open" or "sealed" works for me as a hint only; it should not limit me.
sealed classes are just retrofitting sum types onto the JVM. If Kotlin could have used "enum" for it then they probably would have, like Swift and Rust did.
The main point of sealed classes is exhaustive `when` expressions:
return when (val result = something()) {
Result.Success -> // ...
Result.Failure -> // ...
}
If another subclass appeared at runtime, then the code would fall off the end of that when expression.
Location: Brasilia, DF, Brazil
Remote: Yes
Willing to relocate: No
Technologies: C#, .NET, Asp.NET, Blazor, SQL
Résumé/CV: https://www.linkedin.com/in/clickok/
Email: clickok at gmail.com
Languages: English and Portuguese
Location: Brasilia, DF, Brazil
Remote: Yes
Willing to relocate: No
Technologies: C#, .NET, Asp.NET, Blazor, SQL
Résumé/CV: https://www.linkedin.com/in/clickok/
Email: clickok at gmail.com
Languages: English and Portuguese
Location: Brasilia, DF, Brazil
Remote: Yes
Willing to relocate: No
Technologies: C#, .NET, Asp.NET, Blazor, SQL
Résumé/CV: https://www.linkedin.com/in/clickok/
Email: clickok at gmail.com
Languages: English and Portuguese
According to the rules in the first post, I cannot talk about politics in this thread, but the summary is, the political inclinations that he displayed were "uncomfortable".
Location: Brasilia, DF, Brazil
Remote: Yes
Willing to relocate: No
Technologies: C#, .NET, Asp.NET, Blazor, SQL
Résumé/CV: https://www.linkedin.com/in/clickok/
Email: clickok at gmail.com
Languages: English and Portuguese
I'm a Senior Software Engineer with extensive experience (+25 years). I specialize in solving complex bugs and researching solutions for problems others couldn't resolve.
1. To be alone is FAR better than to be in bad company. And the world is full of bad company. Thousands of people are craving to be alone for this reason.
2. You need to be a nice companion to yourself. If you arrive at this level, when you meet other people, you will be eager to share this amazing companion with others, instead of appearing to be begging not to "be alone".
And one piece of advice:
1. If you are a Christian, it is a great time to learn and enjoy God's company through prayer; you will never be alone again.