|
This particular way of typing things doesn't make terribly much sense, but it demonstrates how you can save syntax. The one method it demonstrates is a lambda, the other (and I think that's the point here) is a Switch expression. I know I miss the latter in my C++ project.
|
|
|
|
|
Too much syntax, kills the syntax
This is just syntactic sugar, probably to make it more accessible to a new generation of programmers. But under the hood it'll still generate the same stuff we grew up with.
I really don't like arguments such as: yes, "but this is shorter", or "you shouldn't use loops anymore"
If you write out stuff in full, intentions become clearer. But hey, I'm just an *old* programmer...
|
|
|
|
|
There comes a point where all these lamdas and expressions become much like Regex. It may be compact, but debugging and validating it is a nightmare. There are only three constructs we need process, decision and loop
Carpe Diem (Seize the fish)
|
|
|
|
|
You don't have nearly enough calls to libraries that have interfaces that reference other libraries, all using dependency injection and so on.... so that getting to the code that does the 2 + 2 is fully a dozen files deep in an outdated package that is no longer maintained.
|
|
|
|
|
Cool kids like functional programming, so this is the new fad. Microsoft evangelists play for them.
|
|
|
|
|
Sad to say, C# is beginning to look more like JavaScript. The readability is lower and with more linq expressions, it takes longer to understand what the code is doing. For true engineering quality code, it should be more readable so there is less wasting of time understanding it.
|
|
|
|
|
I always knew it would come to this. I can see the case for using lambda functions in certain situations but I always regarded their introduction into C# as a bad move due to their potential for abuse. Sometimes adding N dimensions of abstraction is not a good move. I mean, shall we all start doing maths in base 90 just to use fewer digits? How about we join together n to the power of p math opeartors into newer short-hand operators, just to make that calculus even harder to follow? Just think - one hundred lines of calculus could be comprised into a single line!
|
|
|
|
|
cryptic syntax to programmers in other languages. that's why i don't like it.
i always try to write the code in a style that is familiar to all languages.
when as a pascal programmer i started using c it affected my future pascal code. when i got better at javascript it affected my future c code.
this monday at work they told me to use this syntax for delegates (given int add(int a, int b) ):
Func<int, int, int> x;
x = add;
instead of:
delegate int X(int a, int b);
X x = add;
i prefer the later, because it's more language tolerant.
typedef int (*X)(int, int);
X x = add;
type X = function(a, b: integer) : integer;
var x: X = add;
|
|
|
|
|
|
And sometimes I wonder why I stopped doing "Useless IoT item of the weekend".
The Internet of Stupid strikes again ...
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
"Common sense is so rare these days, it should be classified as a super power" - Random T-shirt
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
This is not useless though. especially the part about clicking a button every five minutes to stay online. HAHAHAHAHAHA
To err is human to really elephant it up you need a computer
|
|
|
|
|
Can't you use the user32.dll for that?
M.D.V.
If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about?
Help me to understand what I'm saying, and I'll explain it better to you
Rating helpful answers is nice, but saying thanks can be even nicer.
|
|
|
|
|
but the jobs are so unreliable. It goes to sleep at unspecific times.
To err is human to really elephant it up you need a computer
|
|
|
|
|
What gets me is that this is the 2nd iteration (or 3rd product) they have successfully created, why do they need additional funding to move to the next phase. Me thinks there is a business plan where they get ALL their funding for a new product/version from kickstarter and pocket any profit.
Never underestimate the power of human stupidity -
RAH
I'm old. I know stuff - JSOP
|
|
|
|
|
Businessman from Bury invents crypto mining machines that can run on cow poo
Cows not included.
--
Unless he also has come up with a way of harvesting the methane and carbon di-oxide produced by the cows, this is probably even less environmentally friendly than electricity from fossil fuel plants. To say nothing of the smell.
Freedom is the freedom to say that two plus two make four. If that is granted, all else follows.
-- 6079 Smith W.
|
|
|
|
|
|
|
Right. We don't need crypto stuff nor cows when we go to Mars. Even astronauts produce poop, so let's do something useful[^] with it.
I have lived with several Zen masters - all of them were cats.
His last invention was an evil Lasagna. It didn't kill anyone, and it actually tasted pretty good.
|
|
|
|
|
Just what we need - even more sh*t in the atmosphere.
(OTOH, it's their ass to risk... )
Freedom is the freedom to say that two plus two make four. If that is granted, all else follows.
-- 6079 Smith W.
|
|
|
|
|
Eat up already! We don't have enough fuel to fly home yet!
I have lived with several Zen masters - all of them were cats.
His last invention was an evil Lasagna. It didn't kill anyone, and it actually tasted pretty good.
|
|
|
|
|
Daniel Pfeffer wrote: harvesting the methane and carbon di-oxide produced by the cows Alas (I really mean yipee!) there's even more bad news[^] for the bitcoin kiddie as their bovine bet will also lose value
Ravings en masse^ |
---|
"The difference between genius and stupidity is that genius has its limits." - Albert Einstein | "If you are searching for perfection in others, then you seek disappointment. If you seek perfection in yourself, then you will find failure." - Balboos HaGadol Mar 2010 |
|
|
|
|
|
This may be good for vegetarians, but is likely to be a disaster for the cow population.
Horses uses to be quite common. People used them for transport, motive power, etc. When the internal combustion engine was invented and cars became cheap(er), these horses were no longer needed. Most of them were slaughtered for cat food. If this non-bovine "milk" becomes popular, the same fate is likely to befall the dairy cows.
(I make no comment on the morality or otherwise of eating animals or animal products)
Freedom is the freedom to say that two plus two make four. If that is granted, all else follows.
-- 6079 Smith W.
|
|
|
|
|
Why does this seem like such a good fit?
Software Zen: delete this;
|
|
|
|
|
Do C programmers have no class?
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
"Common sense is so rare these days, it should be classified as a super power" - Random T-shirt
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
I'm struct you'd even think that.
I’ve given up trying to be calm. However, I am open to feeling slightly less agitated.
|
|
|
|