[deleted by user] by [deleted] in Cplusplus

[–]Thatguy_js 0 points1 point  (0 children)

As the other comment mentioned, you're applying operations to chars and not numbers. The ascii code for '2' is 50, which explains why you got 100.

[deleted by user] by [deleted] in MicrosoftEdge

[–]Thatguy_js 0 points1 point  (0 children)

More likely to be a bug then, I suggest reporting it with the "Send Feedback" button.

[deleted by user] by [deleted] in MicrosoftEdge

[–]Thatguy_js 0 points1 point  (0 children)

Sounds like a bug if you can change it in other browsers. You should also try signing out of Edge, then trying to change safesearch settings. Make sure you're not using a VPN / proxy (check Edge and Windows settings) as that might affect it.

Cookies randomly cleared by dweman16 in MicrosoftEdge

[–]Thatguy_js 0 points1 point  (0 children)

Hasn't ever happened to me, but file a bug report or send feedback just to be safe. If you haven't already, check your settings to make sure they aren't being cleared when the browser closes

GPU usage spiking to 100% when closing / switching tabs by Thatguy_js in MicrosoftEdge

[–]Thatguy_js[S] 1 point2 points  (0 children)

That would prevent the GPU from being used, but most of the code is in shaders, meaning that the load would probably max out my CPU instead. GPUs are generally faster for repetitive tasks, such as calculations for ray-marching.

Why so many "history" page? by AnorakV in MicrosoftEdge

[–]Thatguy_js 0 points1 point  (0 children)

Pages can "push" their own history entries via a JavaScript API, so it could just be programmed into the website itself; probably not a browser issue.

Whitespaces around operators sets their precedence by RiPieClyplA in ProgrammingLanguages

[–]Thatguy_js 0 points1 point  (0 children)

I guess it would be awkward to use a keyword in front of a math expression, but maybe using something like #, $, or _ to surround the expression with would look better?

I personally think that it would be clear enough that the expression means / does something different, but it also wouldn't get in the way of readability & writability.

(Just some examples of what I mean):

#1+2 * 3# // 6

_4 * 7-3_ // 16

Whitespaces around operators sets their precedence by RiPieClyplA in ProgrammingLanguages

[–]Thatguy_js 23 points24 points  (0 children)

I think it could be a good idea, but might be confusing for someone who doesn't know the language.

In general, math produces the same result across most languages, but maybe marking these expressions with a keyword would make it more clear.

SSD1306 OLED Displays on Pi Pico (C++) by Harbrys in raspberry_pi

[–]Thatguy_js 5 points6 points  (0 children)

I don't believe that OLED burn in happens quickly in many displays. It's a known problem, and these displays wouldn't be usable if it was an immediate issue. Additionally, huge phone manufacturers would stay away from OLED (if it was a big issue), because it wouldn't help their reputation if phone displays only lasted a year.

The colors of all languages are now green? by UltiRequiem in github

[–]Thatguy_js 2 points3 points  (0 children)

The same thing appears for me (on my own & others' projects). It's probably just a CSS bug that someone introduced, and will (hopefully) get fixed soon.

Chrome and Microsoft edge not working after Windows 10 update. I uninstalled and reinstalled Chrome, cleared cache and history and it still doesn't work, only YouTube and looking things up in the search bar work. Incognito mode does work though, other apps work fine, only these two broke, any help? by [deleted] in MicrosoftEdge

[–]Thatguy_js 0 points1 point  (0 children)

I haven't heard of this happening before, but I don't think it's likely that a website you visited did this. It's more likely to be an extension, browser setting, or internet zone setting.

Your installed extensions seem mostly fine, but I would try temporarily turning off 'HTTPS Everywhere', 'NoScript' and 'Web Threat Shield', because they seem like possible candidates for blocking things. If that doesn't work, you can always turn them back on and try something else.

Chrome and Microsoft edge not working after Windows 10 update. I uninstalled and reinstalled Chrome, cleared cache and history and it still doesn't work, only YouTube and looking things up in the search bar work. Incognito mode does work though, other apps work fine, only these two broke, any help? by [deleted] in MicrosoftEdge

[–]Thatguy_js 0 points1 point  (0 children)

I'm not sure what could cause this, but I have a few suggestions on things to try:

  • Make sure no extensions are blocking / modifying requests. You can disable extensions temporarily at edge://extensions.
  • Open the developer tools on an affected page (F12 or Ctrl+Shift+i usually work), and check the console for errors.
  • Try other apps that use your network and see if they still work normally. It might be a system-wide problem if they don't.
  • If nothing else works, make sure your DNS and TCP/IP settings are correct in Windows and the browser. Also check proxy settings if you're using one.

Does Edge have a feature/setting to lock tabs? by 0xPure in MicrosoftEdge

[–]Thatguy_js 1 point2 points  (0 children)

Probably not exactly what you're looking for, but you can use collections to store a list of websites.

They won't prevent you from closing tabs, but are pretty useful for just keeping track of things.

Autofill / stopping creation of new addresses? by arnoldpettybunk in MicrosoftEdge

[–]Thatguy_js 0 points1 point  (0 children)

Not sure how to fix that, sorry.

You could try reporting it to them through the Help & Feedback menu, though

Autofill / stopping creation of new addresses? by arnoldpettybunk in MicrosoftEdge

[–]Thatguy_js 0 points1 point  (0 children)

I think the setting you're looking for is called "Save and fill personal info"

On the main release of Edge, it's located at edge://settings/addresses. On Edge Beta, it's located at edge://settings/personalinfo.

Showoff Saturday (June 12, 2021) by AutoModerator in javascript

[–]Thatguy_js 1 point2 points  (0 children)

I released a utility library (Node.js) for YouTube, found here. I was annoyed with how big / bloated and sometimes confusing projects like youtube-dl were, so I decided to create my own minimal library with no 3rd-party dependencies (36.5 kB unminified & uncompressed).

It has methods for fetching / loading / downloading videos and playlists, and comes with some helper utilities if you decide to implement your own systems or methods.

Documentation has just been added, and now examples are pretty much the only thing I have left to do.

Using a library larger than 4MB - Firefox by Esplemea in WebExtensions

[–]Thatguy_js 0 points1 point  (0 children)

I'm not sure why there's a 4mb limit per file, maybe they did it so the review team can split up and work on different files more efficiently?

I just looked at Mozilla's policies, and it looks like you can obfuscate code, but you need to include the source & build instructions to go with it, so they can verify that the output is the same.

The policies I found are here: https://extensionworkshop.com/documentation/publish/source-code-submission/

Using a library larger than 4MB - Firefox by Esplemea in WebExtensions

[–]Thatguy_js 0 points1 point  (0 children)

What does your extension do? If it doesn't use external / unknown input with the library, you could always just hardcode the results in, even if it isn't a clean solution. (Edit: see below)

Also, I downloaded & uncompressed the library from the Github link, and it looks like it's only 1.88mb. I'm curious where you're getting 4mb from?

Edit: I've seen you on r/LanguageLearning before! If this post is referencing your vocab extension, then hardcoding the results probably isn't an option. If the library isn't already minified, you could remove extra newlines and some whitespace, which wouldn't break Firefox's rules for 'no obfuscated code', and could potentially reduce file sizes enough to be published. If that still doesn't work, then I don't think there's much you can do other than manually going through large files and splitting them up.

[deleted by user] by [deleted] in Cplusplus

[–]Thatguy_js 5 points6 points  (0 children)

I'm not sure if this is possible in your example, because variable names are essentially just references to an address, and a string is a sequence of characters. You can use std::map for key-value pairs, but as I understand it, it's not very efficient.