General statistics
List of Youtube channels
Youtube commenter search
Distinguished comments
About
Ken Smith
LaurieWired
comments
Comments by "Ken Smith" (@kensmith5694) on "LaurieWired" channel.
Previous
1
Next
...
All
Their are some who suggest stupidity as an explanation.
18
ewe-tube's software is buggy
3
It depends a lot on the system and your luck. On a lot of hardware and software cases, you would get a segmentation fault on the read. In some others, you will just read whatever is next in memory. Remember that RAM is just like a huge array that you get pointers to some elements of. On a few systems, the results can be very strange indeed. I/O devices have memory addresses too. These are usually very large numbers. Reading from an I/O device can have effects.
2
That looked like a quite modern C. Any current version should work
2
Single letter variables seems like a less than ideal thing to do. Compilers allow 32 characters. You can make the first name 32 upper case "O". The next one will have a zero in the right most place and so on like counting in binary. This will let you have a lot of names. #define can define a name to be just about any token so the operators etc can all be made into 32 character things too. The body of the program can then be neat columns of 32 characters to do something like make the US flag running down page.
2
Yes, this is Unix/Linux related. If this was Windows instead, you would have to write "Please Mr. Bill Gates can I have some memory" and then look for the standard answer of "No, I'm using it all"
2
Some women are stuck with that as their normal voice. You need to get over it.
2
On some RTOSes, that is a bad thing to count on
2
Back in the day when viruses got onto your PC via a floppy, there was Valentines Day Malware. Some of it was seriously bad and some just caused you to waste some time. BTW: There were some "off color" jokes about the VDViruses and that protective cover on floppies. I will let the reader imagine them.
2
Borland's TASM was much better. It had a "masm compatibility mode" where it did a bug-for-bug verson, it has the correct masm-like one without the bugs and a mode where it had much improved syntax.
1
@Stakodron Reading off the end of an array can be your issue and it is an easy one to check so check for that but then look at the logic of the code. This is a more likely area for trouble.
1
@redcrafterlppa303 If you read my comment more carefully, you will see that I mentioned that as a case too. "whatever is next in memory" can be read in many cases.
1
"good style" code wastes so much CPU time that it costs about 2 generations of processor speed.
1
Where I may disagree. I expect RISC-5 to gain a lot more ground and that there will be many distros that are interested. The chip performance will still lag too much this year for the RP that does RISC-5 to be mainstreamed. If you want to keep a secret doing put it in the digital domain, mostly. One time pad encryption will remain secure so nations can remain secure if they are careful. Rust got kicked out of the Linux kernel for reasons not to do with the nature of the language. It still is a bit of a fad at the moment. I expect C to remain very common. I expect there to be some trouble with AI generated content. We may see a dip in its use. We may be at a local maxima in the growth curve of AI. As the content on the internet gets to be more and more AI generated and since AI is trained by what is scraped from the internet, we have a positive feedback loop forming and that is a way to get instabilities.
1
There was a slight error. These days on most systems, malloc() does initialize with something. That something, however, is never what you wanted in there. They do this just so you can't snoop on other users etc by malloc()ing memory and then looking to see if anything interesting is in there. I am watching for the ARM ASM part.
1
@virkony In the past, I have found stuff from other users by doing a malloc. If the code doesn't clear the actual RAM involved then it can contain the contents from some other task that did a free.
1
@virkony There are enough cases for it to matter. Malloc also manages huge amounts of memory when needed. I have allocated more RAM than the code size many times.
1
No thanks. Why burn up all the CPU cycles that the silicon engineers worked so hard to get you? If you don't care about speed write in Python.
1
The typecast makes it so all compilers will compile it with no drama. It also is a good way to remind the reader what is happening. I agree about clearing any pointer you free.
1
@redcrafterlppa303 If you cast to the type declared then the reader knows. This reduces the chance of them making an error
1
I disagree with the idea that anyone should start out with C++. There is just too much to learn. If you don't know programming at all, starting with BASIC is a good idea to get the idea of expressions, assignments and for loops. If you don't have access to BASIC, then Javascript can be a good idea because web browsers do it so you have all the needed tools already. The next thing would be to go with C. It you know what a for loop is, you and do a C for loop without too much trouble
1
@purdueschmidt Yes, and when you are in the situation of needing to do this sort of thing, speed likely matters.
1
@redcrafterlppa303 Do you end up with code in the result for the new and delete? If you know the answer is yes then the "0 overhead" claim can't be true.
1
"Over and out" is not said on the radio in real life. Over = "I expect you to talk now" Out = "I am turning off the radio now"
1
There is a proof that there is no pattern in the digits of pi. The fastest sort I know is the so called "radix sort". There is code that does it faster but it uses a hash method that sometimes will take a really long time but most of the time is quick. The "Stalin Sort" is also fast but it works by sending any out of order data to Siberia and claiming it never existed.
1
The cast is fine. It reminds the reader that a cast is happening and some C compilers will issue a warning.
1
Yes, switch to Pascal. It is much better
1
False
1
Previous
1
Next
...
All