thread_id
stringlengths
6
6
question
stringlengths
1
16.3k
comment
stringlengths
1
6.76k
upvote_ratio
float64
30
396k
sub
stringclasses
19 values
unj838
Watched a documentary there called American Factory where a huge corporation spy’s on its workers to see who’s in a union and find ways to fire those who support it. In school I was also taught that when the mafia was prevalent they were able to corrupt a number of unions. Do you feel any unions in the US are effective...
> spy’s on its workers to see who’s in a union and find ways to fire those who support it. Haven't seen the movie, but I suspect that they were trying to identify workers who were trying to form a *new* union, rather than workers who were already part of a pre-existing union. It's very common for companies to disco...
190
AskAnAmerican
unj838
Watched a documentary there called American Factory where a huge corporation spy’s on its workers to see who’s in a union and find ways to fire those who support it. In school I was also taught that when the mafia was prevalent they were able to corrupt a number of unions. Do you feel any unions in the US are effective...
Some unions prey on the employees that they're supposed to support. Some unions are wildly corrupt. Some are inefficient and obstructionist. Some are mostly good, but made mistakes. And some are pretty great. I was in a union that was corrupt and preyed on their own people. I was offered a job selling insurance t...
130
AskAnAmerican
unjawi
Would you have to have an older sample too? How's that work? Edit: You guys are very informed in your fields. I'm impressed. A lot of academic communities act aggressively to those that are uninformed. Thank you all for your answers. Almost like I would need a few years to comprehend your discussions adequately. Weird...
No, you cannot see them with standard DNA sequencing. Although egenetic changes do modify the DNA, they do not modify the actual sequence. You can detect epigenetic modifications with techniques such as chromatin IP, bisulfite sequencing, ATAC-sequencing, and Western blotting, among others; the technique you use depend...
380
AskScience
unjawi
Would you have to have an older sample too? How's that work? Edit: You guys are very informed in your fields. I'm impressed. A lot of academic communities act aggressively to those that are uninformed. Thank you all for your answers. Almost like I would need a few years to comprehend your discussions adequately. Weird...
There is the added complication that there may be tissue-specific differences in epigenetic marks, so you'd need to sample across multiple locations (unlike the case for your genomic sequence, which with some exceptions should be about the same in every cell in your body).
50
AskScience
unlj00
~43% of sites worldwide use Wordpress, however 99% of the front end job descriptions I’ve seen never mention Wordpress and instead mention JS frameworks. 1. Why do you think that is? 2. Am I pigeonholing myself if I were to take a job where they use Wordpress instead of JS framework? 3. Say I take the job and stick wi...
>1. Why do you think that is? Most WordPress sites need minimal development. 90% of it can be managed by a random guy in marketing. That's actually one of the main selling points of WordPress: you don't need to hire a lot of expensive developers.
60
AskProgramming
unlj00
~43% of sites worldwide use Wordpress, however 99% of the front end job descriptions I’ve seen never mention Wordpress and instead mention JS frameworks. 1. Why do you think that is? 2. Am I pigeonholing myself if I were to take a job where they use Wordpress instead of JS framework? 3. Say I take the job and stick wi...
Because companies don't generally need full time employees to build them a static website, and keep it going. The majority of Wordpress sites are built by design agencies and lone wolf designers, or people doing it themselves. This isn't in any way to denigrate Wordpress or the people that use it, by the way. Far from ...
30
AskProgramming
unlolu
Solved: Thank you for your answers, I found perf, gprof, gprof2dot and hotspot, that helps a lot. This tools are available in Linux (Ubuntu/Fedora). \#################### Hi. I don't know how to implement this question. The thing is, I am following some tutorials for developing games with SDL2: Madsycode(youtube), ...
For windows, I love perfview. Steep learning curve though but it will serve you well to invest the time.
30
cpp_questions
unn41s
What would you personally have done more of in your younger life so that you can feel more fulfilled now?
Learned more about finance and invested more, sooner. I’m not doing badly now, but I could have done much better, much earlier if I’d made some relatively small changes to my money habits.
920
AskOldPeople
unn41s
What would you personally have done more of in your younger life so that you can feel more fulfilled now?
Say no about 10x more often. I can't stress this enough. If you feel like somebody can't handle your no, then you are being bullied, pushed around, manipulated, etc by that person. It's a huge red flag. Address elephants in rooms every time I see one (because I'm gonna be the one to do it anyway. I may as well get it...
760
AskOldPeople
unn41s
What would you personally have done more of in your younger life so that you can feel more fulfilled now?
Education, education, education. Have the skills to support yourself. Never depend on a spouse or SO to pay the rent.
660
AskOldPeople
unnbft
Pretty much just the title. Any help would be appreciated just wondering how much of a benefit it is when looking for a job
It's required for certain government or government contractor jobs. However, (in the U.S. at least), you can't just get a clearance if you want one. You require a reason and a sponsor for the clearance. That means you can't get a security clearance until you have landed a job that requires one.
120
AskProgramming
unnbft
Pretty much just the title. Any help would be appreciated just wondering how much of a benefit it is when looking for a job
Already having been cleared in the past is gets you a pretty good leg up on other applicants, and being eligible at all opens up opportunities in a smaller applicant pool than if you aren't, in aerospace (and other military contractors, but the big ones that are hiring in droves are the aerospace people). But you eit...
30
AskProgramming
unngx6
Do most world maps look like [this](https://geology.com/world/world-map.shtml) or like [this](https://www.mapshop.com/world-physical-map-with-wonders-pacific-centered-light-oceans/) I’ve seen some people say the US uses the world map that splits Europe in half and the US is in the middle, but I don’t think that peopl...
The first one is pretty standard.
1,680
AskAnAmerican
unngx6
Do most world maps look like [this](https://geology.com/world/world-map.shtml) or like [this](https://www.mapshop.com/world-physical-map-with-wonders-pacific-centered-light-oceans/) I’ve seen some people say the US uses the world map that splits Europe in half and the US is in the middle, but I don’t think that peopl...
New world on the left, Old world on the right is pretty standard.
1,080
AskAnAmerican
unngx6
Do most world maps look like [this](https://geology.com/world/world-map.shtml) or like [this](https://www.mapshop.com/world-physical-map-with-wonders-pacific-centered-light-oceans/) I’ve seen some people say the US uses the world map that splits Europe in half and the US is in the middle, but I don’t think that peopl...
>I’ve seen some people say the US uses the world map that splits Europe in half and the US is in the middle, but I don’t think that people actually use that. I think that is a type of nautical map, and it's done so both the Atlantic and Pacific can be seen in their entirety
760
AskAnAmerican
uno33m
So i came across AWS and i wanted to know to know if amazon hires those without experience in this field. I wanna learn a lot about AWS from cloud Practioner, developer and devops engineer, i know amazon has resources on their webistes for this but if i were to pass my AWS exam(s) what will the chances be of getting hi...
Maybe work for a Fortune 500 then transfer into the role like I did better option that wait if you wait a little bit skips all the It low wages stuff
70
ITCareerQuestions
uno33m
So i came across AWS and i wanted to know to know if amazon hires those without experience in this field. I wanna learn a lot about AWS from cloud Practioner, developer and devops engineer, i know amazon has resources on their webistes for this but if i were to pass my AWS exam(s) what will the chances be of getting hi...
You may be able to find an junior level AWS position like this one. [https://lensa.com/junior-cloud-engineer--aws-python-rust-java-jobs/des-moines/jd/bc90f1ba802f35dc09592275490716ae?utm\_campaign=google\_jobs\_apply&utm\_source=google\_jobs\_apply&utm\_medium=organic](https://lensa.com/junior-cloud-engineer--...
50
ITCareerQuestions
unof2v
Hey guys, I am a soon to be physics grad, and while I have always enjoyed coding I do think I am a core science at my heart. So why programming? Because I need the money to sustain myself and pay my way through a masters, which can be quite expensive. Also, I need a break from physics for a while. Also can't stay with ...
What the heck does “up until linked lists” mean? That you can’t write code more complex than a linked list? Read it? Understand it? Also, how are you even defining “more complex”, if that’s even what you meant? And, “good understanding of control flow”? I’m no physicist, but sounds like to me: “I have a good underst...
30
AskProgramming
unogs1
I've made a small CLI program in python that solves a problem for me, and could be useful to others. It takes a .json file and converts an array within it to a csv to be edited, then you can send the csv back to overwrite the original array with the new key value pairs in the csv file. There's a few other minor things,...
Open source it, put it up on github, use it as motivation to either get a higher paying job or a better increase from your employer. Profit!
80
AskProgramming
unogs1
I've made a small CLI program in python that solves a problem for me, and could be useful to others. It takes a .json file and converts an array within it to a csv to be edited, then you can send the csv back to overwrite the original array with the new key value pairs in the csv file. There's a few other minor things,...
Quite frankly, this sounds like the kind of quick script that folks bang out every day. However, does this accomplish something that is critical to whatever processes the workflow involving the licensed software requires, and is it something that would normally be done many times during a given project? If so, the si...
50
AskProgramming
unoruu
Let me give some example: int a = 3; #ifdef a cout << a; #else cout << (++a); #endif With the printed result `4`. Based on this example, I assume that preprocessor symbols are not the same as postprocessor symbols, AKA the `a` in `#ifdef a` isn't the same as the `a` in `int a = 3;...
The preprocessor doesn't give a flying crap about your C++ code, other than being syntactically compatible. > \#define a `a` identifiers are now replaced with nothing. You can check by dumping the preprocessed output. https://www.learncpp.com/cpp-tutorial/introduction-to-the-preprocessor/
230
cpp_questions
unoruu
Let me give some example: int a = 3; #ifdef a cout << a; #else cout << (++a); #endif With the printed result `4`. Based on this example, I assume that preprocessor symbols are not the same as postprocessor symbols, AKA the `a` in `#ifdef a` isn't the same as the `a` in `int a = 3;...
The pre-processor is an entirely separate language applied to the source text before the C++ compiler sees it. The preprocessor macros are independent of the language identifiers. In the first example, there is no `a` preprocessor macro defined, so the `#ifdef` branch is elided from the source text as seen by the com...
130
cpp_questions
unoruu
Let me give some example: int a = 3; #ifdef a cout << a; #else cout << (++a); #endif With the printed result `4`. Based on this example, I assume that preprocessor symbols are not the same as postprocessor symbols, AKA the `a` in `#ifdef a` isn't the same as the `a` in `int a = 3;...
#define a means replace `a` with nothing. So the next line becomes int = 3 which is meaningless. `-E` is your friend : https://godbolt.org/z/MsG3EM4Wr
40
cpp_questions
unoyir
So I'm an experienced self taught dev working in the software industry for the past 5 years. My experience with programming includes JS/TS (React), Python and Go. I've been looking to learn a new programming language in my spare time and I'm thinking to branching into a systems/non-gc programming language but im not su...
C
40
AskProgramming
unoyir
So I'm an experienced self taught dev working in the software industry for the past 5 years. My experience with programming includes JS/TS (React), Python and Go. I've been looking to learn a new programming language in my spare time and I'm thinking to branching into a systems/non-gc programming language but im not su...
I'd say C all the way. There are some languages that are arguably better or nicer, but C really forces you to learn it well.
30
AskProgramming
unp4h2
Why are there multiple programming languages?
We've been designing programming languages for about 70 years, and have learned a thing or two in that time. Following from that, researchers like playing with new ideas, and sometimes they catch on outside of an academic context too, and a new language is built around the new idea. Languages have trade-offs. One well...
170
AskProgramming
unp4h2
Why are there multiple programming languages?
Because anyone can write a language. Everyone is smarter than the last person so theirs is the best way. Would it be better if there were only one? And one OS, and one model of car?
100
AskProgramming
unp4h2
Why are there multiple programming languages?
Why are there multiple flavors of food? Why are there different colors of paint? Why are there different kitchen utensils? Why are there different tools? Why are there different sports?
100
AskProgramming
unpguo
I only made a `bidirectional iterator` once before and that was for a `list` a long time ago. So I am uncertain how to do it for a `map` now concerning the `member typedefs` of `std::iterator_traits<It>`. If I am doing `template <tyename K, typename v>` where K is the `key` and V is the `value`, then would ...
`value_type` for associative containers is generally `pair<const Key, Value>`, with everything else following from that. //edit: In case your map type does not store its nodes in a pair, you could consider something like `pair<const Key&, Value&>`.
30
cpp_questions
unppsp
Satellites can sit in orbit. Can missiles do the same?
[Yes.](https://en.wikipedia.org/wiki/Fractional_Orbital_Bombardment_System)
240
AskScience
unppsp
Satellites can sit in orbit. Can missiles do the same?
It's called Fractional Orbital Bombardment system. It does require a missile designed for it. The delta V (change in velocity) requirement is higher than for an ICBM, so it needs either a more powerful missile or/and a lighter warhead, and the missile needs to perform the reentry burn meaning there's different control ...
50
AskScience
unppsp
Satellites can sit in orbit. Can missiles do the same?
[removed]
40
AskScience
unpriy
For me, I think you can get better Italian food than in Italy in some places in the US. What are some foods like this for y’all?
I’m gonna throw a weird one out there, but bagels.
6,050
AskAnAmerican
unpriy
For me, I think you can get better Italian food than in Italy in some places in the US. What are some foods like this for y’all?
May be an unpopular opinion but I prefer American pizza over Italian pizza… and I don’t mean that chain restaurant pizza, but those from small businesses. I remember eating this delicious cheese pizza from NYC on my trip last year and it was better than any pizza I tried at Italy when I went on summer trip there 3 yea...
5,620
AskAnAmerican
unpriy
For me, I think you can get better Italian food than in Italy in some places in the US. What are some foods like this for y’all?
Sorry Germany. America took your burger, ran with it, and got all the gold medals.
3,770
AskAnAmerican
unq2ic
And when I mean modern, I mean the last 10-15 years. What old techology do you really miss?
i dont covet old technology but i do think social media has ruined humanity.
390
AskOldPeople
unq2ic
And when I mean modern, I mean the last 10-15 years. What old techology do you really miss?
I've become a luddite of sort as well. I don't know if I am quite old enough to comment yet (40, b. 1981) but I miss technology from 15 years ago. Algorithms have ruined social media. All these places used to have NO ADS. You OWNED your software and no one could force you to update anything. I read somewhere on red...
200
AskOldPeople
unq2ic
And when I mean modern, I mean the last 10-15 years. What old techology do you really miss?
I’m the 51 year old tech support manager for an office of lawyers ranging in age from late 20s to early 70s. In my experience, no one hates any and all technology like a 35 year old lawyer. I send them instructions on how to change their default browser and they react like I told them they have to compile their own sou...
120
AskOldPeople
unqo55
Can decompression sickness cause pneumocephalus (air in the cranial cavity)?
I don’t think so: * decompression sickness (DCS) doesn’t cause \*air\* anywhere, only nitrogen * nitrogen equilibrates between environment, lungs and blood relatively slowly (compared to oxygen and CO2): DCS is caused by an imbalance between higher tissue concentrations and lower ambient (partial) pressures - nitrogen...
30
AskScience
unqui2
Hello! Logins will be held in a SQL database. We want to limit access to 5 devices simultaneously. If a user will connect from a 6th device and if our app/client is working on all 5 devices, he won't log in.
This works for 5 browsers not 5 devices. Store a generated ID in a cookie and send it with each request, keep an array of the ID associated with the user in the database. Limit the IDs to 5 in the DB. If a request comes from the user and the ID passed with the request isn't in the database IDs, reject the request.
50
AskProgramming
unr0ga
I mean we do have Lady liberty, and uncle sam. Columbia too, along with the obsolete and dated personifications. Like brother Jonathan. But if we were to really capture the USA under one person, who or what would it be?
Lady Liberty isn't a personification. It's a symbol for what we strive to be [It's why China will never see Spiderman: No Way Home](https://screenrant.com/spiderman-no-way-home-finale-china-edit-request/)
420
AskAnAmerican
unr0ga
I mean we do have Lady liberty, and uncle sam. Columbia too, along with the obsolete and dated personifications. Like brother Jonathan. But if we were to really capture the USA under one person, who or what would it be?
Hey now, let's put some respect on Miss Columbia's name why don't we She was a girlboss throughout the 1800s/early 1900s until she was unfairly killed off by the world wars and the "need" for a masculine personification In political comics, she was always a better personification (as was shown to care more about jus...
200
AskAnAmerican
unr0ga
I mean we do have Lady liberty, and uncle sam. Columbia too, along with the obsolete and dated personifications. Like brother Jonathan. But if we were to really capture the USA under one person, who or what would it be?
Trying to capture it as one person would be a disservice to the nation itself.
130
AskAnAmerican
unrc4v
(Sorry I know this is a cpp subreddit but c seems to be inactive) The following is intended to print out statements but in different lines: #include <stdio.h> int main(){ printf("Hello World!"); printf(" "); int number= 1; float percentage= 3.14; cha...
printf doesn't automatically add a newline. u need to add `\n`, ie `printf("hello\n")`. for the percent sign you probably need to escape it since it is a special character. Try `printf("This is the percentage: %f\%", percentage);`
70
cpp_questions
uns7h7
Like if I wanted to stand at the highest and lowest point where would I need to go?
Highest: Mount Whitney Lowest: Death Valley Apparently these are also the highest and lowest points in the contiguous United States.
350
AskAnAmerican
uns7h7
Like if I wanted to stand at the highest and lowest point where would I need to go?
Tallest: Mt Elbert - 14,439 ft. Lowest: Lauren Boebert’s district.
160
AskAnAmerican
uns7h7
Like if I wanted to stand at the highest and lowest point where would I need to go?
[https://en.wikipedia.org/wiki/Britton\_Hill](https://en.wikipedia.org/wiki/Britton_Hill) comes in at a whooping 345 feet summit. Pretty much everywhere else is coast line.
140
AskAnAmerican
unsbpq
Is isolationist sentiment on the rise? Do you think it will continue to grow?
Yes, on both sides of the political spectrum but for different reasons. Republicans are saying other countries have taken advantage of the USA, that they're not paying their fair share to our commitments, and we shouldn't be spending money on foreign aid that could be going to Americans here. Democrats are saying we...
640
AskAnAmerican
unsbpq
Is isolationist sentiment on the rise? Do you think it will continue to grow?
Nice try Vladimir
420
AskAnAmerican
unsbpq
Is isolationist sentiment on the rise? Do you think it will continue to grow?
I think we should help Ukraine, but if you compare the numbers Europe isn't stepping up and doing their fair share. As usual.
400
AskAnAmerican
unsdlz
Evidently there is sulfur and oxygen in magma and it combines to form SO2. What magma chemistry leads to this being a primary constituent of volcanic eruptions?
You answered your question pretty well in asking it: It's a major volcanic emission because sulfur is in solution in magma. There's a fair amount in the earth in general, and it ends up in most magma in some amount, just like silicon, iron, aluminum, calcium, and sodium. When the magma cools, near the surface in the ...
50
AskScience
unsdz4
Would the blood be ‘tainted’? Could it potentially get someone sick? Asking out of curiosity all I could find online is “don’t donate until one week free of symptoms”.
First up, respiratory viruses are not known to be transmitted through blood transfusions. This was confirmed many times during Covid-19. Respiratory viruses mostly live in cells in your airways, they aren't in your blood stream. Even then, not a problem for the recipient (mostly) due to how donated blood is processe...
80
AskScience
unsdz4
Would the blood be ‘tainted’? Could it potentially get someone sick? Asking out of curiosity all I could find online is “don’t donate until one week free of symptoms”.
It's actually....really, really bad if a cold virus gets from your nose/throat/lungs to your blood. Sometimes your digestive tract gets infected, too, but a typical cold infection would leave various *markers* of the infection, from white blood cells etc going to the linings of your airways and other immune processes o...
50
AskScience
unspbx
I've got the following function, which uses `std::make_unique`: void from_json(const nl::json& json, std::unique_ptr<b2Shape>& shape) { const int type{json.at("type").get<int>()}; const nl::json& value = json.at("value"); switch (type) { case...
You can construct a shared_ptr by moving from a unique_ptr So have the shared from_json call the unique one
60
cpp_questions
untk4o
I'm trying to do my own clicker game, and I'd like to do a map like Pokéclicker have, with different single color tiles next to another, with a light grey grid to show the mark between 2 tiles. Any idea how to code that in a proper manner ? I'm thinking something like this [https://i.redd.it/rr4q4mfrbqe61.png](htt...
Sounds like you want to implement a two-dimensional array: https://math.hws.edu/javanotes/c7/s5.html
30
AskProgramming
untutd
In my country same retail chain has different prices for same product in different places which depends on purchasing power of region. Is this a thing in US?
Due to different costs in different states, even different municipalities can have different prices. California retail prices are higher than retail prices in in Texas, for example. You can check [numbeo.com](https://numbeo.com). Retail sites also often ask you to enter to your ZIP code. Nominally, chains like Dolla...
190
AskAnAmerican
untutd
In my country same retail chain has different prices for same product in different places which depends on purchasing power of region. Is this a thing in US?
I believe the Costco food court has the same prices nationwide. other than that, no. Varying cost of living and tax rates make prices fluctuate a lot
30
AskAnAmerican
untutd
In my country same retail chain has different prices for same product in different places which depends on purchasing power of region. Is this a thing in US?
Not really. Sales tax varies though.
30
AskAnAmerican
untx5n
Do you need a supercomputer to train a neural network?
This depends entirely on the size/complexity of the neural network and the data you're working with A neural network can be anything from single-digit amount of neurons to billions, if not trillions, of neurons such as for example GTP-3 You can train a relatively simple neural network on your home computer in a reaso...
100
AskComputerScience
untx5n
Do you need a supercomputer to train a neural network?
No. You might want a bunch of regular computers depending on the size of the net
40
AskComputerScience
unu2s0
My dentist is mad about the stuff, reckons if I can only do one I should floss rather than brush. Good way to stop teeth decay. But what do First Nations culture use if they don’t have plastic?
While dental floss may not have existed many cultures used miswak or need branches that people chew on. They have antimicrobial properties and the ends can be used to dislodge food and brush one's teeth. I'm sure other cultures had similar technology.
40
AskScience
unuevz
What are some crazy/weird laws in your state?
It's illegal to hunt whales in Oklahoma. https://www.knowledgetribe.in/articles/7-unusual-laws-around-world#:~:text=Oklahoma%20has%20a%20law%20which,stringent%20law%20banning%20the%20pastime.
130
AskAnAmerican
unuevz
What are some crazy/weird laws in your state?
In Colorado it's a fairly significant misdemeanor, with possible penalties of up to a year in jail prior to March 1 (not sure how this offense was reclassified), to throw a cigarette out the window of a car It makes sense when you think about the wildfire problems here, but definitely shocking to see how severe it is
100
AskAnAmerican
unuevz
What are some crazy/weird laws in your state?
Restaurants and bars are required to specify which they are. So a restaurant will have a sign stating "This establishment is a restaurant" and a bar stating "This establishment is a bar" or something like that. Up until a year or so ago we weren't allowed to have the same percentage of ABV in our beer as every other st...
90
AskAnAmerican
ununpf
One that sticks with me is "Hold onto yourself, Bartlett. You're twenty feet short."
"Serpentine! Serpentine!"
80
AskOldPeople
ununpf
One that sticks with me is "Hold onto yourself, Bartlett. You're twenty feet short."
I love the smell of Napalm in the morning Apocalypse Now
50
AskOldPeople
ununpf
One that sticks with me is "Hold onto yourself, Bartlett. You're twenty feet short."
'Don't be stoopid. Nobody's jugs're bigger than their neck. ' *Grease*
50
AskOldPeople
unv7pf
I am from india and casual sex is not very common here.And i always hear a lot about america that casual sex and kink parties are common.Can anyone give some idea? By casual sex,i mean people involving physically with other people if they are mutually attracted to each other without committing to one long term partner...
casual sex between two people? very common, mostly through dating apps/college scenes etc. sex parties/orgies? not very common.
1,750
AskAnAmerican
unv7pf
I am from india and casual sex is not very common here.And i always hear a lot about america that casual sex and kink parties are common.Can anyone give some idea? By casual sex,i mean people involving physically with other people if they are mutually attracted to each other without committing to one long term partner...
I used to spend a lot of time in India and I was always surprised at how much sex you guys think goes on here. Like, I used to check into hotels with my wife and they would assume that we were casual friends who were sleeping together (They would say things like, "So, I assume a one-bed room for you and your... Friend?...
970
AskAnAmerican
unv7pf
I am from india and casual sex is not very common here.And i always hear a lot about america that casual sex and kink parties are common.Can anyone give some idea? By casual sex,i mean people involving physically with other people if they are mutually attracted to each other without committing to one long term partner...
> casual sex > >kink parties These two are not as connected as you'd like to think. Its interesting one side of the world thinks we're these sex crazed maniacs and the other side of the world thinks we're stuck up prudes.
700
AskAnAmerican
unv8bo
So I made a little program to calculate marks for test. It's my first project so I may have done something wrong. Here's the code: #include <iostream> #include <fstream> #include <cmath> using namespace std; struct { string fach; f...
You can return strings, exactly like that. Your problem is somewhere else. 1. `struct {...} note;` is a terrible idea. Unnamed types are very rarely useful. 2. Don't use `using namespace std;` 3. Don't use (mutable) global variables 4. `for(int i=num1; i <= str1.length(); i++)` is going out of bounds for `str1[i]`....
120
cpp_questions
unv8bo
So I made a little program to calculate marks for test. It's my first project so I may have done something wrong. Here's the code: #include <iostream> #include <fstream> #include <cmath> using namespace std; struct { string fach; f...
##include <string>
50
cpp_questions
unv8bo
So I made a little program to calculate marks for test. It's my first project so I may have done something wrong. Here's the code: #include <iostream> #include <fstream> #include <cmath> using namespace std; struct { string fach; f...
The function certainly returns a string. But the question is what string? What do you want the function to do? I don't think it does what you want: currently it returns a string which consists of a single character which is the last character of the input argument `str1` unless `num1` is equal to or larger than the len...
40
cpp_questions
unvbom
Hi!, I recently bought a 7tb hdd and replaced a 1tb one in my pc, along with replacing an 220gb system ssd for a bigger one (500gb). I've noticed that after that upgrade, file explorer freezes 50% of the time, working in Blender (software), is much slower, and overall the pc is seeming to struggle. How much does disk s...
Try r/techsupport. As the [posting guidelines](https://old.reddit.com/r/AskComputerScience/comments/bl37qz/read_before_posting/) suggest, this sub is rather for questions about [computer science](https://en.wikipedia.org/wiki/Computer_science). Anyway, to answer the more general question, increased disk space shouldn'...
30
AskComputerScience
unvdzr
Why not just use plates?
There’s a sheet of wax paper in it. Easy to toss and clean the basket without wasting a whole plate
420
AskAnAmerican
unvdzr
Why not just use plates?
Food safety laws are different in every state, but in mine (California) and I assume in many others, the major benefit is cleaning time. Baskets do need to be washed/disinfected, but considering there's rarely any actual food on them once the liner is thrown out, doing so is very fast and easy. They also stack easily, ...
150
AskAnAmerican
unvdzr
Why not just use plates?
To be clear, fast food (McDonald’s, Burger King, Wendy’s, etc) doesn’t have baskets, at least any I’ve ever seen. Places like food stands and diners do. So your question is moot.
60
AskAnAmerican
unwbsj
Are there any free tools and resources to practice with Oracle Cloud Applications? I have seen an internal job opportunity for “ Oracle Cloud Applications Administrator” and was thinking about going for it. Anyone have any experience in a similar position and can provide some insight on what the position does?
Here you go: * https://education.oracle.com/learning-explorer * https://www.oracle.com/education/ * https://education.oracle.com/oracle-certification-paths-all Oracle was giving away free training and exam vouchers for months earlier this year so you might want to keep an eye out to see if they offer more this year.
30
ITCareerQuestions
unwk5i
As the title says. I'm a 25-year old Filipino expat in UAE currently working as a call center rep and I am considering switching to IT field. I do not have a related degree nor work experience in this field but as I did my research online, I can get certifications and start with the basics such as A+ and work my way u...
Jason Dion and Prof Messer Practice tests along with Messer's study groups/videos and ExamCram is what I used for the A+. I'd suggest self study. 4-6 weeks is very rushed. If you practice a lot you'll be fine.
30
ITCareerQuestions
unwq4z
I like Java, C++ and Javascript. However if there's one language that gives me the heebie jeebies........it's Bash 😐 It's so weird. The fact that spaces are important in syntax and how easy it is to overlook an error because of just a space!? And the code itself looks like it was written by an alien.
Like Bash, Perl is a bit of a syntax bastard
150
AskProgramming
unwq4z
I like Java, C++ and Javascript. However if there's one language that gives me the heebie jeebies........it's Bash 😐 It's so weird. The fact that spaces are important in syntax and how easy it is to overlook an error because of just a space!? And the code itself looks like it was written by an alien.
100% Javascript!
130
AskProgramming
unwq4z
I like Java, C++ and Javascript. However if there's one language that gives me the heebie jeebies........it's Bash 😐 It's so weird. The fact that spaces are important in syntax and how easy it is to overlook an error because of just a space!? And the code itself looks like it was written by an alien.
Well OP, just wait for the fun you’ll have with whitespace when you use YAML 😂 I guess PHP and people still using JSP or whatever that ancient Java thing was gives me heebies jeebies, but I generally avoid these things 😛
90
AskProgramming
unxgdl
Our project is compiling with C++17 at the moment and we consider moving up to C++20. We compile to Windows only at the moment, but the issue is that it is very likely that we will have to port it to MacOS and Linux in the future (let's say it for sure won't happen in the next 6 months) I know that gcc and clang are...
https://en.cppreference.com/w/cpp/compiler_support/20 So basically modules and std::format are not portable right now, have fun with the rest.
50
cpp_questions
unxo55
I know it is more of a QoL thing since you can just achieve it through telling everyone on the team to not use it, but it would be very helpful in a codebase touched by many people.
You probably can't within the language. The reason is that `int32_t` is very often just something like `typedef int int32_t;`. Things like [std::is\_same](https://en.cppreference.com/w/cpp/types/is_same) also [think they're the same type](https://godbolt.org/z/v15fv5Mo1). You probably need some compiler-specific stuff ...
250
cpp_questions
unxo55
I know it is more of a QoL thing since you can just achieve it through telling everyone on the team to not use it, but it would be very helpful in a codebase touched by many people.
Id install [git hooks](https://git-scm.com/docs/githooks) to ensure nothing with `int` can be pushed
240
cpp_questions
unxo55
I know it is more of a QoL thing since you can just achieve it through telling everyone on the team to not use it, but it would be very helpful in a codebase touched by many people.
There is no way to do it within the language because the type system does not distinguish between them — `int32_t` is simply a typedef for (typically) either `int` or `long`, meaning they are exactly the same type. That said, there are external tools that can do this for you. I believe there is a clang-tidy rule to en...
90
cpp_questions
unxqbz
I've been working as application support/developer for the last 15 years, and now that I've turned 40, I've found that I am no longer able to effectively deal with the random incidents and major outages, that I used to be able to shrug off and deal with when younger. I'm worried the crushing stress from trying to ge...
You could move into project management? You have the tech background and it’s not firefighting.
700
ITCareerQuestions
unxqbz
I've been working as application support/developer for the last 15 years, and now that I've turned 40, I've found that I am no longer able to effectively deal with the random incidents and major outages, that I used to be able to shrug off and deal with when younger. I'm worried the crushing stress from trying to ge...
Security is an option. Compliance is nice in that aspect, you come in to work, tell everyone how they are doing everything wrong and leave while they stay and fix. There are other parts of security that don’t deal with incidents as well. Your previous experience is a big advantage when working security as well.
520
ITCareerQuestions
unxqbz
I've been working as application support/developer for the last 15 years, and now that I've turned 40, I've found that I am no longer able to effectively deal with the random incidents and major outages, that I used to be able to shrug off and deal with when younger. I'm worried the crushing stress from trying to ge...
Look for a new job as a systems architect.
420
ITCareerQuestions
uny1np
Hi ! I'm having trouble implementing firebase in an iOS app using cpp... I hope you'll be able to help me ^^' Here are the three troublesome files : First, the listener interface from firebase : class Listener { public: virtual ~Listener(); /// Called on the client when a message arrives. /// /// @param[in] m...
Your posts seem to contain unformatted code. Please make sure to format your code otherwise your post may be removed. Read [our guidelines](https://www.reddit.com/r/cpp_questions/comments/48d4pc/important_read_before_posting/) for how to format your code. *I am a bot, and this action was performed automatically. Ple...
40
cpp_questions
uny3eq
Have you ever eaten horseradish?
If we count wasabi as horseradish then yes,a lot of times... every time I eat sushi.
2,030
AskAnAmerican
uny3eq
Have you ever eaten horseradish?
As a Jew I must eat horseradish at least once a year at passover. It's also good with roast beef.
1,840
AskAnAmerican
uny3eq
Have you ever eaten horseradish?
Yes indeed. Particularly if you count cocktail sauce - horseradish being a primary constituent.
1,310
AskAnAmerican
unybzo
altho i learned C/C++ , pointers , OOP design , etc in school but everything i do in job i ve learned on my own during summer breaks or weekends . Go , React , Git , docker to name a few and i believe that this is the case for most of my classmates if not for everyone who works as SWE , it's true that school taught m...
Kind of. Without a traditional CS education - you can go a whole career without understanding the likes of path finding algorithms, OS internals, distributed synchronization primitives, etc so you aren’t forced to learn those things by the industry. However, understanding these concepts will make you a better softwar...
2,650
CSCareerQuestions
unybzo
altho i learned C/C++ , pointers , OOP design , etc in school but everything i do in job i ve learned on my own during summer breaks or weekends . Go , React , Git , docker to name a few and i believe that this is the case for most of my classmates if not for everyone who works as SWE , it's true that school taught m...
IME, the difference between self-taught programmers and formally taught programmers mainly boils down to whether someone else forced them to put some uncommon tools in their “mental toolbox”. Those tools aren’t always used every day (if they were, self-taught folks would learn them), but they are useful occasionally an...
2,540
CSCareerQuestions
unybzo
altho i learned C/C++ , pointers , OOP design , etc in school but everything i do in job i ve learned on my own during summer breaks or weekends . Go , React , Git , docker to name a few and i believe that this is the case for most of my classmates if not for everyone who works as SWE , it's true that school taught m...
a CS degree teaches you the fundamentals that you can apply to most languages
520
CSCareerQuestions
unyg77
Three years ago, we revealed the first image of a black hole. Today, we announce groundbreaking results on the center of our galaxy. We'll be answering questions from 1:30-3:30 PM Eastern Time (17:30-19:30 UTC)! The Event Horizon Telescope (EHT) - a planet-scale array of eleven ground-based radio telescopes forged t...
What is the groundbreaking result?
1,470
AskScience
unyg77
Three years ago, we revealed the first image of a black hole. Today, we announce groundbreaking results on the center of our galaxy. We'll be answering questions from 1:30-3:30 PM Eastern Time (17:30-19:30 UTC)! The Event Horizon Telescope (EHT) - a planet-scale array of eleven ground-based radio telescopes forged t...
I was surprised to see that Sag A* changed in such a short timescale. What's the time resolution you can achieve? I guess you can't image events shorter than one hour or so. What's the limiting factor? Can a image taken over a shorter length of time become less blurred, or is the optical resolution the cause of the blu...
1,230
AskScience
unyg77
Three years ago, we revealed the first image of a black hole. Today, we announce groundbreaking results on the center of our galaxy. We'll be answering questions from 1:30-3:30 PM Eastern Time (17:30-19:30 UTC)! The Event Horizon Telescope (EHT) - a planet-scale array of eleven ground-based radio telescopes forged t...
Can you tell us a bit more about the user interface with the telescope? I can't imagine you're taking turns looking through a single eyeglass.
860
AskScience
unym8g
What American people think about Malcolm X beliefs (the beliefs that he held before his pilgrimage to Mecca) ?
I doubt most Americans have any idea what those beliefs were.
1,400
AskAnAmerican