How did it "miss" that? That might've been the correct choice. Working with inclusive begin exclusive end ranges is the only method that works consistently without getting gaps or overlaps when using not just integers but also floats or date-times. You'll find this in many libraries, e.g. std c++ containers.
the Kris
Posts
-
C# autocomplete -
If you could have only one word on your gravestone...Just "Yes!"
-
Light mode vs. Dark modeI agree, so many people have their screen way too bright. Funny anecdote is that I was told at the time that the switch from dark to light background was made because it is more readable and reduces eye strain.
-
C# vs. JavaScript/Typescript dyslexiaMarc Clifton wrote:
C#: if (!String.IsNullOrEmpty(foo)) JS: if (foo)
Those two are not the same. Consider foo = "0";
-
Notebook fan was going crazy on windows 10....By setting max power state below 100% you essentially disable cpu boost. If that lowers fan noise then some process was using a lot of cpu causing continuous boost. Changing that setting is treating the symptoms, not the cause.
-
CPU: Could you help me understanding it?Maybe this helps a bit? Is about the 4800U though. AMD Ryzen 7 4800U Review, Mind Boggling Performance at 15W https://www.youtube.com/watch?v=hFYdHkvRs2c&t=0s
-
Original Mac Calculator Vs Win10 CalcWell, I use "Microsoft Calculator Plus", and am happy with that one. The built-in win10 one is shit.
-
Need advice for a workstationHe does need a video card. Could go cheaper though.
-
GitFlowMy biggest issue with git flow is the 'Release branches must merge back into master and develop'. When you need to support previous (and long running) releases, it makes zero sense. Git flow, I think, works only if you have the kind of software that can always be upgraded to the latest version, no matter what, and you don't do any bug fixing or small functional additions to prior releases. So you have only one 'master'. Think of MySQL bugfixing 7.x.y (release branch) and then merging that bugfix into the latest development (8.0.x). That bugfix might be in code that even doesn't exist anymore.
-
Best sci-fi movies...I did see Dune in the thread and I like that movie, as well as the book.
-
Debate : Standard v Phillips (Allen, Torx)Pozidriv is not just another name, it is a very different head compared to Phillips. You cannot use a Pozidriv bit on a Phillips head and a Phillips bit on a Pozidriv screw very easily starts stripping. Sometimes wikipedia is the way to go... List of screw drives - Wikipedia[^]
-
If it fails, try againIf that was the problem the author of that code tried to 'fix', (s)he should've added a comment to indicate that.
-
Why not use the same password for all my accounts?Call "0800 am I secure" and say your account number and repeat "My voice is my password" 3 times and we will check for you if it still secure! Call within one hour of this commercial and we'll include some free balls to lick. Privacy guaranteed! Call NOW!
-
Planetary orbit problems againLight does travel in straight lines. It is the space that is curved :)
-
Question for you audiophilesI guess largely correct. The sound of sub-woofers designed to have the cone pointed downwards towards the floor can be affected as the space between the floor and cone acts like a short transmission line or have some other kind of acoustic effect. Please correct if I am totally wrong in my assumption.
-
Quotes from Training Manuals (Not programming training manuals)Is dat printed on what looks to be the back or the front?
-
Code OptimizeIf examining the result while debugging is your main concern, you can still write
int ResultFlag = MSSqlHelper.SqlHelper.ExecuteNonQuery(SqlServerConnection.Cn, CommandType.Text, Sqlstring);
return ResultFlag != 0;
I've seen worse though...
const bool valTrue = true;
const bool valFalse = false;bool doTheWork()
{
...more impressive code...if ( result == valTrue ) return true;
else return false;
}That coder was preparing himself for the time that valTrue became false or something!?
-
Star Trek v Star WarsIf impossible things make it fantasy then there would not be science fiction, it would all be called fantasy. Isn't fantasy more about myth and magic and assigning impossible 'powers' to people and creatures? E.g. 'Heroes' or 'The 4400' is fantasy, ST is science fiction and SW is borderline with this 'force' and all...
-
Celebrity Deathmatch (VB.NET vs C#)Nope, 'cechode' wrote: General Re: Celebrity Deathmatch (VB.NET vs C#) Pin member cechode 23hrs 30mins ago i'm not a vb guy anymore but when i was i LOVED exit on first failed step. ( instead of nested if's ) BTW, I would use
bool s = step1() || step2() || step3();
to execute until first true result. -
Celebrity Deathmatch (VB.NET vs C#)Does
Func<bool>
accept non-bool funcs? If not the other C# examples here only accept bool too. Or am I missing the point here?