r/computerscience 8h ago

Help Drop some interesting algorithm problems

3 Upvotes

Hi guys please kindly share some interesting algorithm problems in the comment section. I did solve many algorithm problems on platforms like codeforces, atcoder, luogu and code chef etc.. looking for some unique ones that are quite challenging and interesting at the same time but kindly don't share open problems .


r/computerscience 8h ago

General Does Replacing Instructions that Do Nothing with NOPs Change Anything?

2 Upvotes

Suppose in the executable, instructions N to N+6 do some load instructions from memory, then N+7 to N+30 are some integer operations like add, subtract, multiply, bitwise operations and so on. the results are not stored to memory. Then Instruction N+31 to N+37 loads new values in the registers and none of the results of the previous calculations do anything. A different version of the executable has instructions N to N+30 all be "NOP" and N+31 to N+37 are the same as before. Does anything change? My inspiration for this is the game Mario 64 had been dissected and if you look at the assembly of the NTCS version, there are plenty of instructions that do some calculations that aren't used and some weird things like loading from the same address to the same register when the register's value could not possibly be changed. At the same time these instructions couldn't outright be removed or the alignment of all the JMPs would be thrown off. My friend said perhaps some NOPs might be done with a lower power consumption than some of the multiplication instructions, but otherwise if the later instructions don't use the results of the extraneous instructions and are unaffected by their flags nothing should change.


r/computerscience 13h ago

IBM quantum computer solves classically intractable problem in 15 minutes

Thumbnail sciencedaily.com
88 Upvotes

"The researchers showed that their method preserves the same computational hardness criteria associated with RCS, meaning the problem remains extremely difficult for classical computers. At the same time, the added structure allows errors to be detected during the quantum computation."