|
|
... and he nearly made it to another Star Wars Day (which is half an hour old here).
Software rusts. Simon Stephenson, ca 1994. So does this signature. me, 2012
|
|
|
|
|
I have been given a list of strings that are actually numeric identifiers; these can autoincremented but I am trying to determine what the actually numbers are, as they contain alphanumeric characters. Can anyone advise on how to do this?
eg. x774b4n, x7741zs, x774ahm, x774cb0
Thanks.
|
|
|
|
|
Start by reading the read text at the top!
Anything that is unrelated to elephants is irrelephant Anonymous
- The problem with quotes on the internet is that you can never tell if they're genuine Winston Churchill, 1944
- Never argue with a fool. Onlookers may not be able to tell the difference. Mark Twain
|
|
|
|
|
unable to delete this posting but reposted under correct forum
|
|
|
|
|
Once answered it can not be deleted.
I can do it for you if you want.
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.
|
|
|
|
|
Quote: Start by reading the read text at the top! Please check your spelling first if you think you need to correct a member
No no, auto correction is not responsible for everything. One should also red the text which one has wrotten....
It does not solve my Problem, but it answers my question
modified 19-Jan-21 21:04pm.
|
|
|
|
|
Don't tell me what to do! You're not my cats!
Anything that is unrelated to elephants is irrelephant Anonymous
- The problem with quotes on the internet is that you can never tell if they're genuine Winston Churchill, 1944
- Never argue with a fool. Onlookers may not be able to tell the difference. Mark Twain
|
|
|
|
|
If only there was a forum for programming questions....
|
|
|
|
|
Are you telling he should try asking in SO?
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.
|
|
|
|
|
Hi,
Base36 and above are the only numeral notations that contain the ascii letter Z.
Best Wishes,
-David Delaune
|
|
|
|
|
All your base are belong to us!
|
|
|
|
|
Hmmmm,
Apparently that's a joke that only us older guys would understand. I made that same joke on reddit a few years ago and was downvoted into oblivion.
Best Wishes,
-David Delaune
|
|
|
|
|
Randor wrote: only us older guys I'm 31
|
|
|
|
|
parse tables are especially lovely.
How often do you get to declare nasty things like this?
IDictionary<int, IDictionary<int, KeyValuePair<int, int>>>
or
Tuple<TAccept, Tuple<KeyValuePair<char, char>[], int>[]>[]
I have a headache in my eye.
When I was growin' up, I was the smartest kid I knew. Maybe that was just because I didn't know that many kids. All I know is now I feel the opposite.
|
|
|
|
|
It's containers, all the way down!!
|
|
|
|
|
The issue is dependencies. These are opaque structures used to hold parse tables and FA state tables. They're static initialized and not mutable, and basically opaque to the end developer.
I thought about creating types to better encapsulate this data in a more friendly manner, but that just means extra type declarations in the end developer's code for something they will never use directly.
So meh. It's whatever. But creating them is a PITA
When I was growin' up, I was the smartest kid I knew. Maybe that was just because I didn't know that many kids. All I know is now I feel the opposite.
|
|
|
|
|
codewitch honey crisis wrote: but that just means extra type declarations in the end developer's code for something they will never use directly
That makes sense. It's always an issue of trade-offs with this kind of stuff.
|
|
|
|
|
codewitch honey crisis wrote: but that just means extra type declarations If the "extra" types make the code more readable, they go from being "extra" to "recommended".
/ravi
|
|
|
|
|
since the code is never touched by humans, and only generated by tools, it doesn't need to be readable. it doesn't even step through in the debugger (DebuggerHidden)
adding, putting in a bunch of extra code they have to include and understand into their projects makes adoption *more* not less difficult
When I was growin' up, I was the smartest kid I knew. Maybe that was just because I didn't know that many kids. All I know is now I feel the opposite.
|
|
|
|
|
|
haha looks like fun
When I was growin' up, I was the smartest kid I knew. Maybe that was just because I didn't know that many kids. All I know is now I feel the opposite.
|
|
|
|
|
Don't use a tuple like that!
(TAccept meaningfulNameInsteadOfItem1, (KeyValuePair<char, char>[] keys, int something)[])[] So much more readable... Ok, I guess just don't do this
In such scenario's I usually create a class, which may inherit from Dictionary<...>, for readability.
Or I do something like:
var lookup = originalCollection.ToLookup(i => i.Key, v => v.ToLookup(...)); So that I never have to specify the type
|
|
|
|
|
I haven't used that syntax before. I know it's available but i just haven't touched it.
I'm relatively new to the more modern iterations of C#.
Luckily this type is used to store machine generated tables and isn't touched by the end-developer at all. That profoundly limits the impact of using non-descriptive names
That being said I updated my code according to your suggestion. Thanks!
When I was growin' up, I was the smartest kid I knew. Maybe that was just because I didn't know that many kids. All I know is now I feel the opposite.
modified 3-May-19 5:34am.
|
|
|
|
|
I was moving a bit of code just yesterday and I had a class with two properties to return a result from a function.
That was the only place where the class was used and other than that it didn't add anything of value.
Of course, back in the day you could use an out parameter if you had more than one return value, but that is now frowned upon.
So then I remembered C# has introduced named tuple values and I rejoiced.
Never again will I use these multiple-return-values-from-function-classes anymore
Had you posted this the day before yesterday I wouldn't have known either
I've been using LINQ for years though (and even rewrote it in JavaScript[^]).
It's been making life so much easier
|
|
|
|