thread_id
stringlengths
6
6
question
stringlengths
1
16.3k
comment
stringlengths
1
6.76k
upvote_ratio
float64
30
396k
sub
stringclasses
19 values
umgtsg
Basically a question on self sufficiency!
Most states would be fucked in this context. The US is reliant on cross-border travel for just about everything
4,380
AskAnAmerican
umgtsg
Basically a question on self sufficiency!
I feel like most states would struggle for a while if this happened. We would have serious water issues to deal with.
3,970
AskAnAmerican
umgtsg
Basically a question on self sufficiency!
Extremely. A lot of people won't be able to get to work or home. Even using public transit to travel within the state will become impossible.
3,760
AskAnAmerican
umhb2t
With the symptoms being so close to the common cold or a flu, wouldn't most doctors have simply assumed that the first patients were suffering from one of those instead? What made us suspect it was a new virus, and not an existing one?
The symptoms were nothing like the cold or flu, thousands were dying in Asia. Virus samples are frequently DNA sequenced worldwide as part of a monitoring program. A new sequence was correlated with high death rates or need for ventilators. A better question is once we knew for certain we had a new and deadly variant of coronavirus, why did most of the world do nothing to prevent inter-country spread until mid 2020. Protocols were developed in 2003 during the SARS outbreak, and none were followed.
28,150
AskScience
umhb2t
With the symptoms being so close to the common cold or a flu, wouldn't most doctors have simply assumed that the first patients were suffering from one of those instead? What made us suspect it was a new virus, and not an existing one?
I work in Healthcare. Let me tell you, COVID is nothing like the cold or flu. We had people coming into the hospital being so sick and not recovering no matter what we did for them. We immediately knew something was wrong and that a ton of people were developing this illness, we just didn't know what it was right away. I can recall patients being sick at the end of 2019 and the healthcare team (us) being on edge because they weren't necessarily recovering. Then 2020 rolls around and this new illness is classified as COVID. Edit: Clarifying
3,640
AskScience
umhb2t
With the symptoms being so close to the common cold or a flu, wouldn't most doctors have simply assumed that the first patients were suffering from one of those instead? What made us suspect it was a new virus, and not an existing one?
It was not really that close to the common cold or the flu. People seem to forget how serious COVID-19 was when it first broke out. Our current situation with the Delta and Omicron, which have a lot lower mortality, has changed our perception of COVID. Serious cases of COVID required ventilators, which the cold and flu usually don't need. There was also clotting and organ damage. There is also the loss of taste, which is a very strange symptom. They would have noticed these strange symptoms and investigated, especially after autopsies. Then they would have done numerous tests for bacteria, fungi and virus due to the number of patients, and found out about COVID.
2,000
AskScience
umhioy
Mine were Betty Rubble (*The Flintstones*), Mary Ann Summers (*Gilligan's Island*), and Jeannie (*I Dream of Jeannie*). Edit: I just remembered another early TV crush, Agent 99 on *Get Smart*.
The original Batgirl, Yvonne Craig (from the Adam West Batman).
400
AskOldPeople
umhioy
Mine were Betty Rubble (*The Flintstones*), Mary Ann Summers (*Gilligan's Island*), and Jeannie (*I Dream of Jeannie*). Edit: I just remembered another early TV crush, Agent 99 on *Get Smart*.
The 3 girls skinny dipping in the water tower at the beginning of Petticoat Junction.
370
AskOldPeople
umhioy
Mine were Betty Rubble (*The Flintstones*), Mary Ann Summers (*Gilligan's Island*), and Jeannie (*I Dream of Jeannie*). Edit: I just remembered another early TV crush, Agent 99 on *Get Smart*.
Keith Partridge (David Cassidy) from ‘The Partridge Family’ 😍❤️
360
AskOldPeople
umhwwc
I'm currently writing a novel and trying to find (semi-)plausible reasons for how and why future rich people are able to change fundamental characteristics of their own bodies. Those changes would range from eye- or haircolor to changes in hormone production or even changing which parts of the body are able to regenerate and which are not. My limited knowledge makes me think it's indeed not possible but I'm definitely not qualified to make any assumptions which is why I'm asking here!
Not with our technological level. Color change might be possible in future, eg. by gene editing therapy(eg. Imprinting gene code with virus), assuming that method will be faster than organism autocorrection mechanisms. Even then- it will take time, enough time for old cells to die off specifically speaking Regeneration of lost body parts would need changes that would make subject not longer a human. "Lab" grown tissue technically can be transplanted in place of lost one
80
AskScience
umhwwc
I'm currently writing a novel and trying to find (semi-)plausible reasons for how and why future rich people are able to change fundamental characteristics of their own bodies. Those changes would range from eye- or haircolor to changes in hormone production or even changing which parts of the body are able to regenerate and which are not. My limited knowledge makes me think it's indeed not possible but I'm definitely not qualified to make any assumptions which is why I'm asking here!
I can imagine an engineered virus with a crispr protein specifically tailored to the target person's genes to change a trait like that. If normal biology would not replace the cells fast enough I'm sure there's a hormone cocktail that could be locally administered to help. Maybe this is a taxing operation, or maybe they have drugs to help with that? Could also be interesting if, say, the targeted virus accidentally started to work on a family member who was not supposed to know about some deception, but they weren't getting the localized helper medications so it just takes a really long time to "reveal"?
80
AskScience
umhwwc
I'm currently writing a novel and trying to find (semi-)plausible reasons for how and why future rich people are able to change fundamental characteristics of their own bodies. Those changes would range from eye- or haircolor to changes in hormone production or even changing which parts of the body are able to regenerate and which are not. My limited knowledge makes me think it's indeed not possible but I'm definitely not qualified to make any assumptions which is why I'm asking here!
[removed]
60
AskScience
umhysk
What facts about the United States do foreigners not believe until they come to America?
I've encountered many people who underestimate how big it is. I know some folks from South Korea, whose country is functionally an island (ocean on three sides and a closed border on the fourth). They can drive from one end of the country to the other in a matter of hours. They intellectually knew America was very large, but until they spent hours in a jet it didn't click just how incredibly huge it really is. Try flying over the southwestern desert regions and realizing "Holy crap, it just *keeps going*."
12,290
AskAnAmerican
umhysk
What facts about the United States do foreigners not believe until they come to America?
This might be better addressed to non-Americans. But visitors I've met had a hard time understanding the size of the country, the distances Americans routinely drive, and the lack of good alternatives to driving or flying.
8,950
AskAnAmerican
umhysk
What facts about the United States do foreigners not believe until they come to America?
My dad was an immigrant from Britain in the 60s. All his family is still over there. So I'll share some things that have mystified my relatives over the years, when they visited. The spread-out nature of things, obviously. Intersections of two four-lane streets seem like parking lots to them. Insect life. My cousins were baffled by the winking green lights in the air in the summer, and thought I was messing with them when I told them they were bugs. I had to catch one and show them. Some of my relatives have been genuinely freaked out by how LOUD the cicadas and crickets and grasshoppers can get in the evening. The idea of that density of insects, that they can be loud enough you have to raise your voice to be heard over them, was freaky to them. The heat. They would always arrive excited for warm weather, and then after a couple of days they'd realize there is a difference between warm and HOT. Fortunately my parents' house had a pool so they could jump in there and recuperate from the high-90s weather. Guns. It seemed so weird to them that we would drive down my city's main drag and pass four or five gun stores, or be on the highway and see a huge billboard reading "GUNS NEXT EXIT." I remember my cousin saying "Who is buying guns so casually that they're on their way to somewhere else and see this billboard, and they're like *oh let's pull off here and get some guns*?" Or how so many shops and restaurants have signs on the door saying "Weapons prohibited." The fact that we need to *specify that* is crazy to them. The free refills thing, and soft drinks coming out of "taps" (drinks fountains) baffled my one cousin when we were kids, and as adults he told me he had assumed there were underground pipes for every conceivable soft drink beneath every American town, because he thought of them as taps and that's how water gets to water taps. When we were teenagers I tried to take my cousins camping and caving. The caving terrified them, and after that they flat-out refused to sleep in a tent in the woods so we had to get a motel room. I'm not an hardcore outdoorsy guy, but I took it for granted they would enjoy some outdoors like I did. They did not. Years later they are still telling people about their crazy American cousin taking them down into the perilous inky black bowels of the earth hahaha. One of them has a wife, and she was laughing about this family legend, and I was like, "You know that cave I took them to that they still haven't forgiven me for? That was where I took my wife on our first date." And they all just shook their heads. Country poverty. They have poor people everywhere, but in Europe it's mostly urban I guess, and rural poverty looks different, and more depressing.
8,870
AskAnAmerican
umik09
Why is there no tick prevention for humans? You can buy prevention for dogs that lasts for months without reapplication, but for humans the best we can do is a bug spray that sometimes works.
There is a project underway to develop a 'vaccine' to ticks. Normally we don't notice ticks as their bites don't cause an immune reaction. If we can prime the immune system to react to tick bites, then the resulting inflammation and itching would let us know it was there, and allow removal before it had a chance to properly feed and transmit Lyme or similar diseases. https://www.newscientist.com/article/2297648-mrna-vaccine-against-tick-bites-could-help-prevent-lyme-disease/
45,350
AskScience
umik09
Why is there no tick prevention for humans? You can buy prevention for dogs that lasts for months without reapplication, but for humans the best we can do is a bug spray that sometimes works.
[removed]
31,750
AskScience
umik09
Why is there no tick prevention for humans? You can buy prevention for dogs that lasts for months without reapplication, but for humans the best we can do is a bug spray that sometimes works.
The main thing only touched upon is simply: Humans regularly bathe. The dogs get the chemical into them and it settles on their skin, and that’s that. It will say right on the application notes that any regular swimming or bathing will necessitate earlier reapplication. Imagine bathing every 0.5-2 days for the entire month, with soap. Not to mention humans change their “fur” daily also which will also carry away some of the chemical. This is from the [K9 Advantix II Tick/Flea FAQ](https://ca.mypetandi.com/our-products/advantix/) > Baths can be given as often as once per month without affecting the performance of the product. If more than one bath is given, K9 Advantix®II should be reapplied after the second bath. So basically you get one bathing before the product is no longer effective. So you could do it and just not bathe for a month if you’d want.
12,750
AskScience
umkpaf
When did you realize that Lily Tomlin was married to a lady?
I didn’t notice. And now that I know I still don’t care.
250
AskOldPeople
umkpaf
When did you realize that Lily Tomlin was married to a lady?
Just now, from you, OP. Now I have another irrelevant, unsurprising factoid cluttering up my brain. Thanks.
180
AskOldPeople
umkpaf
When did you realize that Lily Tomlin was married to a lady?
Apparently today.
140
AskOldPeople
uml7ef
What facts do Americans usually not believe about the rest of the world, until they see or experience it for themselves?
I wouldn't have guessed that Quebec has a French-language version of American pop country music. But then I strayed into the upper range of the SiriusXM dial.
3,980
AskAnAmerican
uml7ef
What facts do Americans usually not believe about the rest of the world, until they see or experience it for themselves?
I didn’t think the Swiss were so crazily rules oriented until I went there and saw a sign with a high heel shoe with a circle and slash through it. This was on a mountain ridge trail in the high alps. They felt the need to make sure no one was trying to hike that trail in high heels. Another trail had a sign that asked you to keep your children on a leash. It looked just like the ones for dogs but had a symbol for a kid rather than a dog.
3,140
AskAnAmerican
uml7ef
What facts do Americans usually not believe about the rest of the world, until they see or experience it for themselves?
The US isn't the most -ist or -phobe country by a long shot. It's just one of the countries that actually shine a light on it.
3,010
AskAnAmerican
umlyj7
First love. 1967, Ford Galaxy Police Tin Cruiser. What was yours?
1960 Karmann Ghia
30
AskOldPeople
umnbhx
What star was closest to the Sun 305 million years ago? Is it even possible to predict their positions that far back?
Sun [orbits Milky Way every 230 million years. ](https://astronomy.com/magazine/ask-astro/2020/07/in-which-direction-does-the-sun-move-through-the-milky-way) 305 million / 230 million = 1.3 orbits in the past. 305 million years ago the Sun was surrounded by a group of stars, one of which would have been the closest. [This video shows that nearby stars](https://youtu.be/hvEHnvkABas) orbiting the Milky Way get smeared out into a long arc. [This article](http://beyondearthlyskies.blogspot.com/2013/04/nearest-stars-past-present-and-future.html?m=1) shows the closest star to Earth is going to change in about 25,000 years. These two points suggest to me that astronomers can't determine the closest star to the Sun 305 million years ago.
90
AskScience
umnbhx
What star was closest to the Sun 305 million years ago? Is it even possible to predict their positions that far back?
It's currently impossible to know what the closest star to the Sun was 305 million years ago. It may be possible in many decades, but currently our best information can only tell us the closest stars +/- about 2-3 million years from now.
40
AskScience
umnmhb
I am working on the following problem regarding RTL notation. What is the effect of the following sequence of RTL instructions? Describe each one individually and state the overall effect of these operations. Note that the notation \[x\] means the contents of memory location x. a. \[5\] ← 2 b. \[6\] ← 12 c. \[7\] ← \[5\] + \[6\] d. \[6\] ← \[7\] + 4 e. \[5\] ← \[\[5\] + 4\] I understand what is happening in a - d. However the double brackets in e. are confusing me. Is it saying place the contents of memory location 5 are being added to the contents of memory location 4 and stored back into 5? That would make the most sense, only that nothing was ever loaded into \[4\]...so that just throws me off a bit.. Like I said I understand everything else. I appreciate any help or direction. edit: Thank you to everyone that helped!
> Is it saying place the contents of memory location 5 are being added to the contents of memory location 4 and stored back into 5? No, that would be [5] ← [5] + [4]. You can analyze expressions like this by looking at them "inside-out". That is: * What does it mean to evaluate the expression [5]? You're given the definition: it means reading the contents of memory location 5? * What does it mean to evaluate the expression [5]+4? It means to add the expression [5] (which you figured out in the previous step) to the *value* 4. * What does it mean to evaluate [[5]+4]? I'll leave this one for you.
40
AskComputerScience
umnmhb
I am working on the following problem regarding RTL notation. What is the effect of the following sequence of RTL instructions? Describe each one individually and state the overall effect of these operations. Note that the notation \[x\] means the contents of memory location x. a. \[5\] ← 2 b. \[6\] ← 12 c. \[7\] ← \[5\] + \[6\] d. \[6\] ← \[7\] + 4 e. \[5\] ← \[\[5\] + 4\] I understand what is happening in a - d. However the double brackets in e. are confusing me. Is it saying place the contents of memory location 5 are being added to the contents of memory location 4 and stored back into 5? That would make the most sense, only that nothing was ever loaded into \[4\]...so that just throws me off a bit.. Like I said I understand everything else. I appreciate any help or direction. edit: Thank you to everyone that helped!
Brackets are denoting memory location. c is saying that the contents of memory address 7 will contain the result of adding the contents of memory address 5 with the contents of memory address 6. d is saying that the contents of memory address 6 will contain the result of adding the contents of memory address 7 with the number 4. Nothing is stored in memory address 4.
30
AskComputerScience
umnpdc
So recently I learned that there are about 1 million people of romani gypsy descent in the U.S. Do they face discrimination like in Europe? Are most people cool with them? I am just an European and thought it was interesting to know because here racism against them is Jim Crow era style. Thanks for all the replies in advance.
Not in any real sense. The word "gypsy" itself has little real meaning in the United States.
15,180
AskAnAmerican
umnpdc
So recently I learned that there are about 1 million people of romani gypsy descent in the U.S. Do they face discrimination like in Europe? Are most people cool with them? I am just an European and thought it was interesting to know because here racism against them is Jim Crow era style. Thanks for all the replies in advance.
Americans largely don't have a concept of "gypsies." In America, "traveler" means something different and is definitely not an ethnic/racial group - it generally means people of all backgrounds who are some type of homeless, and go from place to place. Perhaps some proportion of the roma population in America are "travelers" but I don't know. This is not something most people here really think about.
6,790
AskAnAmerican
umnpdc
So recently I learned that there are about 1 million people of romani gypsy descent in the U.S. Do they face discrimination like in Europe? Are most people cool with them? I am just an European and thought it was interesting to know because here racism against them is Jim Crow era style. Thanks for all the replies in advance.
I didn't learn that Gypsy was considered a slur (or even what it actually meant) until I was in my 20s. it's widely used to mean, like, someone who is a free spirit/hippie type (and not in a negative way). there's a Lady Gaga song called gypsy that basically refers to "gypsy life" as having no plans and being free or whatever. it's a good look into what the word means for most Americans. so, no, I don't think there's the same kind of discrimination against Romani people here. my guess is that if a Romani person told a random American they are Romani, they'd have to explain what that is.
5,680
AskAnAmerican
umo52o
I’m starting to wonder if there’s any evidence of humans beings purposefully eradicating another species, purely for the benefit of our survival. I know we’ve already made efforts to eliminate the Guinea worm and are pretty close on that end, but I’m wondering if there are other species that used to exist but we had to kill off because it was too dangerous to co-habilitate with.
The smallpox virus is as good as extinct. There are still some samples of it [kept in Russian and USA labs for research purposes.](https://www.niaid.nih.gov/diseases-conditions/smallpox) We are working on making polio extinct. My vote goes to making bedbugs extinct next! Edit: … and pubic lice are becoming rare in the West due to the fashion for shaving pubic hair, but I consider that to be a happy side-effect of fashion and not intentional.
90
AskScience
umo52o
I’m starting to wonder if there’s any evidence of humans beings purposefully eradicating another species, purely for the benefit of our survival. I know we’ve already made efforts to eliminate the Guinea worm and are pretty close on that end, but I’m wondering if there are other species that used to exist but we had to kill off because it was too dangerous to co-habilitate with.
This isn’t a proper answer because the species has survived, but it’s my impression that we almost did this to the American bison. I remember learning in social studies classes ages ago that the company or companies that built the transcontinental railroad hired hunters to slaughter as many of them possible. (“Buffalo Bill, Buffalo Bill, / Never missed and never will / And the company pays his buffalo bill.”) I seem to remember that the reason was two-fold. I seem to remember that they thought the vast migrating herds might have caused problems with the building and maintenance of the tracks. Also—and perhaps more important—they were the primary resource native groups on the Great Plains relied on, so slaughtering them was basically an indirect form of genocide, which the railroad companies and the settlers and the US government considered desirable. So it was basically an example of trying to eradicate another species as a way of eradicating a group of people. I have read that the population of bison collapsed from tens of millions to less than a thousand in the late 1800s, so that was quite close to total extinction. It’s my understanding that the species only survived because aggressive conservation measures were undertaken at that point.
50
AskScience
umo52o
I’m starting to wonder if there’s any evidence of humans beings purposefully eradicating another species, purely for the benefit of our survival. I know we’ve already made efforts to eliminate the Guinea worm and are pretty close on that end, but I’m wondering if there are other species that used to exist but we had to kill off because it was too dangerous to co-habilitate with.
[removed]
50
AskScience
umostn
As the title explains I'm looking for a plotting library for C++ that is simple to use and that can be compiled on windows with the MinGW g++ compiler. I have been looking for a while but can't find anything that compiles correctly. Are there any go-to libraries that you guys use that are simple to start using?
> Are there any go-to libraries that you guys use that are simple to start using? Python and matplotlib. I write my simulation code in C++, write out datafiles, load them in python and then plot there. Do you really need plotting capability in C++? Usually you write C++ because you need the speed and usually your programs take quite a while to run. So you will have to store the results anyways, as you wouldnt want to rerun the entire thing just because an axis label is wrong. Hence you might as well use the frankly superior matplotlib.
110
cpp_questions
umostn
As the title explains I'm looking for a plotting library for C++ that is simple to use and that can be compiled on windows with the MinGW g++ compiler. I have been looking for a while but can't find anything that compiles correctly. Are there any go-to libraries that you guys use that are simple to start using?
Maybe Matplot++ is the solution. You can check more info in https://github.com/alandefreitas/matplotplusplus
50
cpp_questions
umostn
As the title explains I'm looking for a plotting library for C++ that is simple to use and that can be compiled on windows with the MinGW g++ compiler. I have been looking for a while but can't find anything that compiles correctly. Are there any go-to libraries that you guys use that are simple to start using?
I'd recommend just writing the data out to file and using gnuplot. Its scripting language is a little quirky but since it's a domain-specific language designed for plotting it'll feel more natural than anything else. Plus with some tweaking the output looks really good.
30
cpp_questions
umpirv
Context: I'm a software engineer with about 10 years of experience, all in higher-level languages (C#, Scala, Python, Typescript). I learned enough C to wrap my head around the C memory model. But parts of C++ memory management are still throwing me for a loop. Specifically, I'm finding it *very* hard to figure out when constructors are called implicitly, and particularly when move constructors are called implicitly. So Explain it Like I'm Five: how to move constructors work, when and where are they called implicitly, and what should a correctly written move constructor do?
First note that all of this also applies to the distinction between copy- and move-assignment operators. > how to move constructors work, Depends entirely how you define them. There is nothing in C++ that forces you to define a move constructor. You can get away with just a copy constructor (and maybe a copy assignment operator). That said, the core point on why we have copy vs move comes from an intersection of ownership and object lifetimes. A class may own some resource external to it, e.g. a `std::string` owns a dynamically allocated array that is external to it, which is managed through the `string` object. To ensure consistency, if you copy the string, then you want the array to be copied, meaning a new allocation would happen. But sometimes the copy is undesired. For a function parameter you could pass by reference, but that doesnt always apply. That is why we have move semantics. To pass ownership of some resource owned by one object into another object. > when and where are they called implicitly Rarely. Most of your objects will have a name or some way to reference them(e.g. an index into an array), meaning they are all l-values leading to copy constructor calls. You only move from an object when you know that you wont need it anymore. Generally the language does not make that assumption (even though it may be able to prove that you dont use an object anymore). Move-assignment operators are probably more commonly implicitly invoked: vector<int> f() { return { 0, 1, 2, 3 }; } vector<int> vec = f(); //gets entirely ellided, with no special constructor called. vec = f(); //does move assignment. > and what should a correctly written move constructor do? It should move the ownership from one objec to another and leave the moved-from object in at least a valid-to-destroy state. It is however usually advised to leave the moved-from object in the same astats as a default constructed object. What this means in practice of course depends on your type. Consider struct my_string { char* data = nullptr; // ... loads of cool code to make this thing useful ... my_string( my_string&& other ) noexcept : data( std::exchange( other.data, nullptr ) ) { } ~my_string() { delete[] data; } }; So the move constructor does two things: 1. It takes the pointer that is originally in `other` into its own internal pointer. This way its "taking ownership" 1. It sets `other.data` to `nullptr`. That way when `other` is destroyed, it doesnt delete the buffer we took ownership of.
60
cpp_questions
umpirv
Context: I'm a software engineer with about 10 years of experience, all in higher-level languages (C#, Scala, Python, Typescript). I learned enough C to wrap my head around the C memory model. But parts of C++ memory management are still throwing me for a loop. Specifically, I'm finding it *very* hard to figure out when constructors are called implicitly, and particularly when move constructors are called implicitly. So Explain it Like I'm Five: how to move constructors work, when and where are they called implicitly, and what should a correctly written move constructor do?
https://www.youtube.com/watch?v=Bt3zcJZIalk
40
cpp_questions
umqweo
For a template class `A`I can do template instantiation like this `template class MyClass<int>` and put into a cpp file. How would do this if I have templated function `A::foo` as shown below? void A { template<typename T> //edit: made typo and didn't include arguments void foo(T t); }; Okay figured it out: template A::foo(int);
template void A::foo<int>(); After your edit, as you deduced template A::foo(int); or template A::foo<int>(int);
30
cpp_questions
umrg1y
Wikipedia says that it's pending, and that there are a bit of divergence on wether or not to declare it extinct. Why is that?
Congaree National Park is a vast area near where I live that is presumed to be one place the Ivory-Billed woodpecker might be. Friends of mine that are interested in the champion trees of the park talk about four-day expeditions through the swampland, and say that it could very well exist there, but it’s so hard to navigate some areas. There’s a video out there of a potential sighting, it’s incredibly grainy and likely a decade old at this point. This is 100% hearsay, but I think it strikes at why they aren’t entirely considered extinct. Hopefully we can find one in the swamps soon, because they are truly beautiful birds (although I have only seen pictures). They have plenty of hiding places in the park, haha
50
AskScience
umrg1y
Wikipedia says that it's pending, and that there are a bit of divergence on wether or not to declare it extinct. Why is that?
US Fish and Wildlife declared it extinct last fall. However. There is a [pre-published journal article](https://www.discoverwildlife.com/news/new-paper-suggests-that-ivory-billed-woodpeckers-still-live-on/) floating around, recently, that claims to have video evidence of Ivory-Billed in a remote Louisiana forest. We will have to wait on the authors and journal process to see what this new evidence is.
50
AskScience
ums6bd
The [video](https://www.youtube.com/watch?v=73uATsa8y5Y). Also, do you, as natives, have some problems with understanding some specific dialects/accents?
I definitely couldn't figure out all the words, but it's partially because I'm not really used to listening to Scottish accents. I've found that the more I hear someone speaking with a particular accent, the easier it is for me to understand other people with the same accent.
490
AskAnAmerican
ums6bd
The [video](https://www.youtube.com/watch?v=73uATsa8y5Y). Also, do you, as natives, have some problems with understanding some specific dialects/accents?
Here's what I got with the first 30 seconds or so, with no captions (Scout's honor): ("Kevin, what's your name?") "My name's Kevin Patterson, and I'm a guide at \[Something something\]. We're standing here, down in the Borders, and we're just outside of Melrose, which is a famous town. Over to the back of us here, we have the \[no idea\], one of the most famous landmarks in the Borders, it's three hills. And the myth is that Merlin the Magician split one hill into three. At the left, the two hills at the back of us, which you can see..." \[Something about how if they're covered in fog/clouds, you won't be getting good weather. He then describes that he's a guide on the River Tweed.\] I don't see doing all 4:35, but does that give you a rough idea of what got through?
370
AskAnAmerican
ums6bd
The [video](https://www.youtube.com/watch?v=73uATsa8y5Y). Also, do you, as natives, have some problems with understanding some specific dialects/accents?
He speaks a bit fast, but I can understand him. His accent isn't the problem, it's the speed and enunciation. Is the interviewer Southern? The guy asking the questions sounds like he could be from Tennessee.
280
AskAnAmerican
ums8uw
Can anyone correct my understanding of the two. From what I can see associated functions are functions that don't have self as a parameter and methods are the ones which do? Is that correct or all functions defined within an imp block are associated functions even the methods with self parameter??
Your second definition is correct. See the [relevant section](https://doc.rust-lang.org/book/ch05-03-method-syntax.html#associated-functions) of the rust book. All functions defined on a type in an `impl` block are associated functions as they are associated with a specific type. Methods are simply associated functions with a receiver of `self`, `&self`, `&mut self`, `self: Box<Self>` etc. and can be called with the [dot operator](https://doc.rust-lang.org/nomicon/dot-operator.html) as `foo.bar()` rather than just `Foo::bar()`.
70
LearnRust
umsfya
no i do not have obsession with modern c++, BUT i have a project where i have to use every possible way to make it as modern as it can get. i worked with old c like apis, and i worked with std::11 supported systems, but not with "ultra modern" example: \- no raw pointer, only smart ones. \- lambdas everywhere \- thing what can be done with std::11,14,17,20 so for example no int arr\[10\] -> i use vector. my question, can you please help me with examples? for example what can i change #define MY\_CONST\_STRING "my\_const\_string"? should i use constexpr std::string\_view{"my\_const\_string"}?
Using features for the same of it can lead to pretty bad code. There is nothing wrong with a raw pointer (as long as its not owning and couldnt be a reference instead). There is nothing wrong with plain functions (even though a lambda might enable better optimizations). For a list of new and old features as well as their support status, refer to https://en.cppreference.com/w/cpp/compiler_support
240
cpp_questions
umsfya
no i do not have obsession with modern c++, BUT i have a project where i have to use every possible way to make it as modern as it can get. i worked with old c like apis, and i worked with std::11 supported systems, but not with "ultra modern" example: \- no raw pointer, only smart ones. \- lambdas everywhere \- thing what can be done with std::11,14,17,20 so for example no int arr\[10\] -> i use vector. my question, can you please help me with examples? for example what can i change #define MY\_CONST\_STRING "my\_const\_string"? should i use constexpr std::string\_view{"my\_const\_string"}?
Lambdas and smart pointers are 20 years old. Hardly "modern". Also, depending what you mean with "lambdas everywhere", that's not modern, that's just a bad idea. This is weird request, but what you probably want is to go to C++23 draft, check what's implemented and then go back using the highlights. The `const(init,eval,expr)` keywords, concepts, contracts (?), spaceship. fmt, ranges etc.
190
cpp_questions
umsfya
no i do not have obsession with modern c++, BUT i have a project where i have to use every possible way to make it as modern as it can get. i worked with old c like apis, and i worked with std::11 supported systems, but not with "ultra modern" example: \- no raw pointer, only smart ones. \- lambdas everywhere \- thing what can be done with std::11,14,17,20 so for example no int arr\[10\] -> i use vector. my question, can you please help me with examples? for example what can i change #define MY\_CONST\_STRING "my\_const\_string"? should i use constexpr std::string\_view{"my\_const\_string"}?
Make the entire library constexpr. Never take an exact type as a parameter, template every constructor and function argument and use concepts to constrain them. Make sure that a noexcept version of every function, constructor, operator, etc is possible so that you don't have to pay for what you don't want to use. Embrace transactional programming techniques to make your code and your user's code as exception-resilient as possible (but not in noexcept call paths, as it creates unnecessary runtime costs) Inheritance by composition and polymorphism by type erasure and templatization only. Wherever SIMD vectorization is possible, make it happen. Every object that internally allocates should take as a template argument a type that is constrained by a concept to match the public API of pmr::memory_resource except the requirements that functions are virtual (or better yet, the composable allocator API that Andrei Alexandrescu recommended in his 2015 cppcon talk about allocators: see https://github.com/lukaszlaszko/allocators ) Don't forget to aggressively support coroutines.
110
cpp_questions
umsvcb
Did you cohabitate before marriage?
Born in 67. Never thought about it. Lived with both my ex wives before marriage. Apparently I'm a shitty husband or ignore red flags. My guess is both. My parents were born in the late 30's. They both lived with partners after they were divorced. I think it's been pretty normal since the late sixties unless you grew up in a very conservative area.
770
AskOldPeople
umsvcb
Did you cohabitate before marriage?
I wouldn't marry someone I hadn't lived with for at least two years I also wouldn't live with someone unless marriage was in the future. You learn a lot about someone when you live with them. When I was growing up, I'm 55, it was fairly common to cohabitate before marriage.
540
AskOldPeople
umsvcb
Did you cohabitate before marriage?
You’re dumb if you don’t. Bought our first house before we were married, lived together a while before that. Never knew anyone that really frowned on it
480
AskOldPeople
umtasc
Is Computer Science considered Engineering even though there isn't technically a governing body for it?
Computer Science (especially theoretical computer science) is sometimes classified more as a branch of mathematics. Makes more sense to talk about engineering in terms of software development. A lot of software developers hold a computer science degree, which I think is where the overlap is. In many places, they're commonly called "software engineers", but this sometimes upsets licensed Engineers, regulatory boards, etc. I'm not sure of the current state, legally-speaking, in many places. I found [an announcement](https://ncees.org/ncees-discontinuing-pe-software-engineering-exam/) that the National Council of Examiners for Engineering and Surveying was discontinuing their PE exam for Software Engineering after the 2019 session, due to lack of interest.
60
AskComputerScience
umtasc
Is Computer Science considered Engineering even though there isn't technically a governing body for it?
It started in Mathematics.
40
AskComputerScience
umvae3
Hi there! I'm a software engineer (25 years old), developing apps using Flutter. I like it, there are many cool aspects but a great piece of my heart is C++ lover and I try to keep studying it. I bought "The C++ programming language" by Stroustrup, I'm half way right now and it explains a lot of things but I think I need to read it more times. Meanwhile I try to code in C++ what my brain can imagine, for example I'm writing a repository on GitHub composed by many algorithms all written in C++ where I try to use all my new knowledge but I feel that isn't enough. I would like to make desktop apps, work with DBs...But if I don't have a specific job to do I feel like this is something but isn't enough to really dirt my hands, furthermore I have already seen these stuffs, now I would like to know and do something more that Dart (or other high level languages) can't allow me to do (use pointers for example). With Flutter the beginning was easier for me because there are many discord servers, videos...I mean, make apps with it is also intuitive because we use apps daily but C++ is like something that you don't see but it's there and you can do so many things that find the right one to start could be very hard. That's why I'm here, do you have any suggestion on what I could do to improve my skills in a serious manner? I can join projects to help people, I would be very happy to join a team and meet new people with my same interests so we can grow together.
Do some projects, try some code challenges in c++, try fixing a bug in some open source software.
40
cpp_questions
umvae3
Hi there! I'm a software engineer (25 years old), developing apps using Flutter. I like it, there are many cool aspects but a great piece of my heart is C++ lover and I try to keep studying it. I bought "The C++ programming language" by Stroustrup, I'm half way right now and it explains a lot of things but I think I need to read it more times. Meanwhile I try to code in C++ what my brain can imagine, for example I'm writing a repository on GitHub composed by many algorithms all written in C++ where I try to use all my new knowledge but I feel that isn't enough. I would like to make desktop apps, work with DBs...But if I don't have a specific job to do I feel like this is something but isn't enough to really dirt my hands, furthermore I have already seen these stuffs, now I would like to know and do something more that Dart (or other high level languages) can't allow me to do (use pointers for example). With Flutter the beginning was easier for me because there are many discord servers, videos...I mean, make apps with it is also intuitive because we use apps daily but C++ is like something that you don't see but it's there and you can do so many things that find the right one to start could be very hard. That's why I'm here, do you have any suggestion on what I could do to improve my skills in a serious manner? I can join projects to help people, I would be very happy to join a team and meet new people with my same interests so we can grow together.
Just code. Build a desktop music file organizer. Or build a http server, or build a messaging app. Just code.
40
cpp_questions
umvjq4
Right now I'm riding on "Think you used enough dynamite there, Butch?"
Gentlemen, you can't fight in here! This is the War Room!
200
AskOldPeople
umvjq4
Right now I'm riding on "Think you used enough dynamite there, Butch?"
"What we're dealing with here is a complete lack of respect for the law."
100
AskOldPeople
umvjq4
Right now I'm riding on "Think you used enough dynamite there, Butch?"
["could be raining"](https://www.youtube.com/watch?v=mC4VflOayBw) *Young Frankenstein (1974)*
90
AskOldPeople
umvkle
I've been on diets since I was 12. I understand the importance of being at a healthy weight, but for hell's sake it's getting harder and harder to lose weight as I age (I'm female). Did you give up or do you continue to work at being your best self instead of eating all of the things?
Never decided *that*. I watched my dad and my uncle and my mom all get fat when they hit their 40s. I vowed not to let that happen and so far so good. Portion sizes, what you bring into the house (they were avid pop, ice cream, chips kind of people) and what you use as cooking oil are important. Also movement and activity. My grandfather was my size and weight all his life and I intend on walking in his footsteps. Still use a pushmower to cut my lawn, still do a big veg garden, still go for a mile walk every night and yoga before bed. Zero snacks is a biggie.
600
AskOldPeople
umvkle
I've been on diets since I was 12. I understand the importance of being at a healthy weight, but for hell's sake it's getting harder and harder to lose weight as I age (I'm female). Did you give up or do you continue to work at being your best self instead of eating all of the things?
I'm the opposite. I've been fat most of my life and never put priority on getting into shape, but getting closer to retirement made me kick things into gear. What's the point of all the retirement money I've been saving if I'm not healthy enough to enjoy it, y'know? I'm in my late forties and lost 50 pounds in the past year with this motivation.
390
AskOldPeople
umvkle
I've been on diets since I was 12. I understand the importance of being at a healthy weight, but for hell's sake it's getting harder and harder to lose weight as I age (I'm female). Did you give up or do you continue to work at being your best self instead of eating all of the things?
Eat all the things. Gave up this year. 52.
340
AskOldPeople
umvm1o
can someone help me with some <graphics.h> fonctions in c++ ,thank you
`<graphics.h>` is a museum piece now. How about something non-ancient like SFML.
110
cpp_questions
umvyo9
Background: I've got an abscessed tooth right now, and in addition to antibiotics, my dentist prescribed T3s for pain management. It suddenly occurred to me that across two countries, three cities, five dentists, and ~50 years, I have NEVER been given any other painkiller prescription. For non-dental surgery I've had a wide gamut of painkillers: T3, Oxycodone, Naproxen, and a whole pile of others. But for dental work, it's Tylenol 3, only and exclusively. Is there something about it that is particularly well-suited for dental work, or is it more a case of tradition? (Aside: Ibuprofen is currently working far better for my pain than the T3s, presumably because it's reducing inflammation.)
I am in dental school and we were just talking about this today. Atleast in the USA, 10 or so years ago dentists were among the the highest over prescribers on narcotics aka opium derived pain killers such as hydrocodone. Dentists were an easy target for narcotic seekers, especially young dentists who just graduated and did t know any better. According to our professor. There have been studies done that show most dental work only requires Tylenol or Ibuprofen for dental work. Ibuprofen when there is inflammation. T3 w/ codeine the one that is still prescribed sometimes otherwise our school does not prescribe any other narcotics for dental work. And that is from the lead oral surgeon professor who deals with the cases that theoretically should have the most possible pain.
240
AskScience
umvyo9
Background: I've got an abscessed tooth right now, and in addition to antibiotics, my dentist prescribed T3s for pain management. It suddenly occurred to me that across two countries, three cities, five dentists, and ~50 years, I have NEVER been given any other painkiller prescription. For non-dental surgery I've had a wide gamut of painkillers: T3, Oxycodone, Naproxen, and a whole pile of others. But for dental work, it's Tylenol 3, only and exclusively. Is there something about it that is particularly well-suited for dental work, or is it more a case of tradition? (Aside: Ibuprofen is currently working far better for my pain than the T3s, presumably because it's reducing inflammation.)
Alternating acetaminophen and ibuprofen every three hours is commonly advised for dental pain at the dental school clinic in my area. I'd expect them to be on top of best practices. https://www.ada.org/resources/research/science-and-research-institute/oral-health-topics/oral-analgesics-for-acute-dental-pain >A recent systematic overview in JADA including data on over 58,000 patients following third-molar extractions found that when comparing the pain-reducing efficacy of NSAIDs and opioid analgesics, the combination of 400 mg ibuprofen with 1,000 mg acetaminophen was more effective than any opioid-containing regimen and was also associated with a lower risk of adverse events.
70
AskScience
umvyo9
Background: I've got an abscessed tooth right now, and in addition to antibiotics, my dentist prescribed T3s for pain management. It suddenly occurred to me that across two countries, three cities, five dentists, and ~50 years, I have NEVER been given any other painkiller prescription. For non-dental surgery I've had a wide gamut of painkillers: T3, Oxycodone, Naproxen, and a whole pile of others. But for dental work, it's Tylenol 3, only and exclusively. Is there something about it that is particularly well-suited for dental work, or is it more a case of tradition? (Aside: Ibuprofen is currently working far better for my pain than the T3s, presumably because it's reducing inflammation.)
Studies (Moore et al.) show that staggering ibuprofen and Tylenol is actually the most effective course for dental pain, such as after an extraction. If you’re in pain because of an infection - which is very often the case, an antibiotic is often what will actually manage the pain much more effectively, as it is actually helping what is causing the pain. I see dozens of emergency walk ins / toothaches a week, and I maybe write for controlled substances less than 5 times a week. What I tell patients is that narcotics don’t really do much for dental pain, they more help you sleep / make the acute phase more manageable if it’s something that is just crazy painful - but there are better ways to manage it. Patients regularly tell me that ibuprofen is more effective than Norco for their dental pain. When I was in school we would routinely give 20+ Vicodin for an easy tooth extraction. The reasoning? We were told that it was what patients expected and if we didn’t give them out in private practice patients would be upset / not come back because they thought we were mean. And then the opioid epidemic hit and it’s now the total opposite , but honestly it’s for the best. I see so many patients that are in recovery, and many of them had their first exposure to drugs from a dentist when they got their wisdom teeth taken out.
40
AskScience
umvzho
Did anyone ride a motorcycle during those years and if so what year, make and model? I had a friend who had a restored Triumph Tiger and it was a cool bike.
I rode a Tiger a few times. Liked it. I was heavy into MC between about 63 and 68. Road raced up and down the West Coast, traveled with a Suzuki dealership that also sold Triumphs, and whoa, did we ever like the Suzuki better. Japanese bikes were still pretty much disposable at the time, but they were getting as fast as the British bikes in some ways, and the 250cc class was dominating road racing, beating bigger bikes. My best bike was a Suzuki X6, AKA T-20, AKA "Hustler". A two-stroke twin with a 6 speed transmission, and slingshot acceleration. Our dealership built one into a full-blown road racer that was competitive at the national level. We won a bunch of trophies, and novice-professional points, and when our probationary period was up, we quit. Serious professional racing required more to win, than we had available to offer. Tons of fun while it lasted. I've owned several bikes since then, and wouldn't mind one today. I've never been a "biker", although I sense that their love of motorcycles is as real as mine. I just don't see the need for it to be an entire way of life. Even though it was for a few years, I looked like a normal norman off the bike.
60
AskOldPeople
umvzho
Did anyone ride a motorcycle during those years and if so what year, make and model? I had a friend who had a restored Triumph Tiger and it was a cool bike.
I am woman and I used to ride motorcycles but not until 1998. I'm disabled now mentally and physically and will never ride again, but I used to say that riding a MC was like being on a carnival ride for hours at a time. My license plate frame says, "Live to ride."
60
AskOldPeople
umvzho
Did anyone ride a motorcycle during those years and if so what year, make and model? I had a friend who had a restored Triumph Tiger and it was a cool bike.
I had a 1963 Honda 150 ([CA95](https://www.bike-urious.com/baby-dream-1964-honda-ca95-benly/)) in high school (1970).
50
AskOldPeople
umw3ig
Hi team, As the title, any good lightweight c++ local socket library recommendation for embedded Linux for inter process communication? thanks guys!
ZeroMQ for the win! https://zeromq.org/ They recently introduced new thread safe patterns of scatter/gather and client/server, in addition to the many previous other patterns. (By thread-safe they mean more than one thread can read/write to the same socket.) It is ultra-high performance (it was selected as the protocol for the large hadron collider at CERN which deals in tera and peta-byte scale - per day - processing). We are talking hundreds of thousands of messages per second. What's better is you can easily switch from in-memory message transfer between threads, to interprocess communication using Unix sockets for IPC, to TCP to scale up your deployments from multi-threaded to multi-process to multi-server deployments simply by changing your urls protocol and addresses and appropriate. Currently supported protocols include tcp, udp, pgm, epgm, inproc and ipc. Finally, it is ported to many programming languages. Say you want to do some high speed processing in C++, send some data to a python app to do machine learning with TensorFlow, and then return the result to C++ to resume high performance process. With ZeroMQ this becomes very easy. Combine that with a high performance messaging serialization library like Google protocol buffers and now you can weave magical constructs, scaling to hundreds or thousands of nodes. I have had very good results with both of these technologies on raspberry pi. Happy coding! /Edit for typos
60
cpp_questions
umw3ig
Hi team, As the title, any good lightweight c++ local socket library recommendation for embedded Linux for inter process communication? thanks guys!
I've found NNG to be high quality, also has less restrictive license. https://nng.nanomsg.org/ ZeroMQ is another one.
30
cpp_questions
umw3ig
Hi team, As the title, any good lightweight c++ local socket library recommendation for embedded Linux for inter process communication? thanks guys!
I'd look for some shared memory libraries. Lower overhead than sockets.
30
cpp_questions
umw5mv
Hi all. I found that on [this webstite](https://www.digitalwelt.org/en/digital-subcultures/scam-baiting-hacking/) there are some words that won't show anything on Google if I copy-paste them ("Vayne-RaT" for instance). [Webpage section with unsearchable words](https://preview.redd.it/rxl4m32qhqy81.png?width=823&format=png&auto=webp&s=f8555f3a6061d9a5ae8a12575b3828613e267b3f) I've found that actually what is going to the clipboard is a weird formatted string disguised as the normal text, for this I have used a clipboard viewer tool. This is the content that is being sent to the clipboard: [Clippboard content with weird-formatted words highlighted](https://preview.redd.it/cxn4l3k0iqy81.png?width=821&format=png&auto=webp&s=15a5cd4ac23d5a8a28ee79c374102638ae5410cf) So the question is, how did he do that?
Looks like he's replacing characters in the strings with ones which look very similar (or identical) in Unicode (vs plain ascii). For example: `CrunchRAT` typed out manually == `43 72 75 6e 63 68 52 41 54` https://cyberchef.org/#recipe=To_Hex('Space',0)&input=Q3J1bmNoUkFU   `СrunсhRАΤ` copied from his article == `d0 a1 72 75 6e d1 81 68 52 d0 90 ce a4` https://cyberchef.org/#recipe=To_Hex('Space',0)&input=0KFydW7RgWhS0JDOpA   I used CyberChef to pull/identify these (links above)
100
AskComputerScience
umw5mv
Hi all. I found that on [this webstite](https://www.digitalwelt.org/en/digital-subcultures/scam-baiting-hacking/) there are some words that won't show anything on Google if I copy-paste them ("Vayne-RaT" for instance). [Webpage section with unsearchable words](https://preview.redd.it/rxl4m32qhqy81.png?width=823&format=png&auto=webp&s=f8555f3a6061d9a5ae8a12575b3828613e267b3f) I've found that actually what is going to the clipboard is a weird formatted string disguised as the normal text, for this I have used a clipboard viewer tool. This is the content that is being sent to the clipboard: [Clippboard content with weird-formatted words highlighted](https://preview.redd.it/cxn4l3k0iqy81.png?width=821&format=png&auto=webp&s=15a5cd4ac23d5a8a28ee79c374102638ae5410cf) So the question is, how did he do that?
The way the author did it isn't difficult, etagawesome has a great explanation. The thing I wonder is *why* the author would do it. It seems like strange wannabe hacker tactics; anyone reading the article could obviously search for the terms, but why would they want to prevent people from searching it in the first place?
60
AskComputerScience
umw5mv
Hi all. I found that on [this webstite](https://www.digitalwelt.org/en/digital-subcultures/scam-baiting-hacking/) there are some words that won't show anything on Google if I copy-paste them ("Vayne-RaT" for instance). [Webpage section with unsearchable words](https://preview.redd.it/rxl4m32qhqy81.png?width=823&format=png&auto=webp&s=f8555f3a6061d9a5ae8a12575b3828613e267b3f) I've found that actually what is going to the clipboard is a weird formatted string disguised as the normal text, for this I have used a clipboard viewer tool. This is the content that is being sent to the clipboard: [Clippboard content with weird-formatted words highlighted](https://preview.redd.it/cxn4l3k0iqy81.png?width=821&format=png&auto=webp&s=15a5cd4ac23d5a8a28ee79c374102638ae5410cf) So the question is, how did he do that?
whatever technique he used, it doesnt work in firefox, nothing is obfuscated, copy-pasting vayne-rat works edit: Feature Policy: Skipping unsupported feature name “accelerometer”. www-widgetapi.js:961:251 Feature Policy: Skipping unsupported feature name “autoplay”. www-widgetapi.js:961:251 Feature Policy: Skipping unsupported feature name “clipboard-write”. www-widgetapi.js:961:251 Feature Policy: Skipping unsupported feature name “encrypted-media”. www-widgetapi.js:961:251 Feature Policy: Skipping unsupported feature name “gyroscope”. www-widgetapi.js:961:251 Feature Policy: Skipping unsupported feature name “picture-in-picture”. www-widgetapi.js:961:251 found that in the console, i see some clipboard-write stuff
50
AskComputerScience
umwxey
When you make a root beer float, do you put in the ice cream or soda first?
Ice cream then soda. If you put the ice cream in after it'll splash.
1,440
AskAnAmerican
umwxey
When you make a root beer float, do you put in the ice cream or soda first?
ice cream!
1,340
AskAnAmerican
umwxey
When you make a root beer float, do you put in the ice cream or soda first?
Ice cream. Fill the glass. The root beer fills the cracks, and partially solidifies, coating the scoops of ice cream with sweet goodness.
420
AskAnAmerican
umxe7i
Mine is Sicilian & Eskimo cultures.
Yeast. Very versitile. Very underappreciated even among biologists.
1,290
AskAnAmerican
umxe7i
Mine is Sicilian & Eskimo cultures.
Kefir. Yogurt cultures get a lot of attention for promoting gut health, but kefir is the top notch probiotic option.
490
AskAnAmerican
umxe7i
Mine is Sicilian & Eskimo cultures.
They all have some good little thing going for them. But as a whole, Western Civilization, obviously, whatever its imperfections. There's just no contest.
230
AskAnAmerican
umxgx4
I am very new to C++ and programming in general. I don't understand why this is happening. Thank you in advance for any help. I feel very lost. The error messages look like this: `Error C2039 'print': is not a member of 'std::basic_string<char,std::char_traits<char>,std::allocator<char>>'` I get an error for every function from student.h when I use it in roster.cpp. roster.cpp #include <iostream> #pragma once #include <ostream> #include "roster.h" #include "student.h" #include <string> using namespace std; void Roster::classRosterParse(string studentData) { size_t rhs = studentData.find(","); string studentID = studentData.substr(0, rhs); size_t lhs = rhs + 1; rhs = studentData.find(",", lhs); string firstName = studentData.substr(lhs, rhs-lhs); lhs = rhs + 1; rhs = studentData.find(",", lhs); string lastName = studentData.substr(lhs, rhs - lhs); lhs = rhs + 1; rhs = studentData.find(",", lhs); int age = stoi(studentData.substr(lhs, rhs - lhs)); lhs = rhs + 1; rhs = studentData.find(",", lhs); int daysInCourse1 = stoi(studentData.substr(lhs, rhs - lhs)); lhs = rhs + 1; rhs = studentData.find(",", lhs); int daysInCourse2 = stoi(studentData.substr(lhs, rhs - lhs)); lhs = rhs + 1; rhs = studentData.find(",", lhs); int daysInCourse3 = stoi(studentData.substr(lhs, rhs - lhs)); lhs = rhs + 1; rhs = studentData.find(",", lhs); string strDegreeProgram = studentData.substr(lhs, rhs - lhs); DegreeProgram degreeProgram = SECURITY; if (strDegreeProgram == "Network") { degreeProgram = DegreeProgram::NETWORK; } else if (strDegreeProgram == "Software") { degreeProgram = DegreeProgram::SOFTWARE; }; }; void Roster::printDegree(DegreeProgram degreeProgram) { for (int i = 0; i < Roster::amountOfStudents; i++) { if (classRosterArray[i]->getDegreeProgram() == degreeProgram) { classRosterArray[i]->print(); }; } }; void Roster::printInvalidEmail() { bool any = false; for (int i = 0; i < Roster::amountOfStudents; i++) { string emailAddress = (classRosterArray[i]->getEmailAddress()); if (emailAddress.find(" ") || !emailAddress.find("@") || !emailAddress.find(".")) { any = true; cout << classRosterArray[i]->getEmailAddress() << endl; }; } if (!any) cout << "NO INVALID EMAILS" << endl; }; void Roster::printAverageDaysInCourse(string studentID) { for (int i = 0; i < Roster::amountOfStudents; i++) { cout << (classRosterArray[i]->getDaysInCourse()[0] + classRosterArray[i]->getDaysInCourse()[1] + classRosterArray[i]->getDaysInCourse()[2]) / 3 << endl; } }; void Roster::addStudentData(string studentID, string firstName, string lastName, string emailAddress, int age, int daysInCourse1, int daysInCourse2, int daysInCourse3, DegreeProgram degreeProgram) { int daysArray[3] = { daysInCourse1, daysInCourse2, daysInCourse3 }; // classRosterArray[amountOfStudents+1] = new student(studentID, firstName, lastName, emailAddress, age, // daysArray, degreeProgram); }; void Roster::removeStudentData(string studentID) { for (int i = 0; i <= amountOfStudents; i++) { if (classRosterArray[i]->getStudentID() == studentID); } }; void Roster::printAll() { for (int i = 0; i < Roster::amountOfStudents; i++) { classRosterArray[i]->print(); } }; void print(); student.h #pragma once #include <iostream> #include <iomanip> #include <stdio.h> #include "degree.h" using std::string; using std::cout; class student { public: student(); student(string studentID, string firstName, string lastName, string emailAddress, int age, int daysInCourse[], DegreeProgram degreeProgram); ~student(); //how many classes they were taking const static int totalDays = 3; private: //defines the format of the information for each student string studentID; string firstName; string lastName; string emailAddress; int age = {}; int daysInCourse[totalDays] = {}; DegreeProgram degreeProgram = {}; public: //getters string getStudentID(); string getFirstName(); string getLastName(); string getEmailAddress(); int getAge(); int* getDaysInCourse(); DegreeProgram getDegreeProgram(); //mutators void editStudentID(string studentID); void editFirstName(string firstName); void editLastName(string lastName); void editEmailAddress(string emailAddress); void editAge(int age); void editDaysInCourse(int daysInCourse[]); void editDegreeProgram(DegreeProgram degreeProgram); void print(); }; student.cpp #include <iostream> #include "student.h" using std::string; using namespace std; const static int totalDays = 3; //getters string student::getStudentID() { return studentID; }; string student::getFirstName() { return firstName; }; string student::getLastName() { return lastName; }; string student::getEmailAddress() { return emailAddress; }; int student::getAge() { return age; }; int* student::getDaysInCourse() { return daysInCourse; }; DegreeProgram student::getDegreeProgram() { return degreeProgram; }; //mutators //"this->" is a pointer that you use when two elements have the same name, use it to link to the class object void student::editStudentID(string studentID) { this->studentID = studentID; }; void student::editFirstName(string firstName) { this->firstName = firstName; }; void student::editLastName(string lastName) { this->lastName = lastName; }; void student::editEmailAddress(string emailAddress) { this->emailAddress = emailAddress; }; void student::editAge(int age) { this->age = age; }; void student::editDaysInCourse(int daysInCourse[]) { for (int i = 0; i < totalDays; i++) this->daysInCourse[i] = daysInCourse[i]; }; void student::editDegreeProgram(DegreeProgram degreeProgram) { this->degreeProgram = degreeProgram; }; //whole record void student::print() { std::cout << getStudentID(); std::cout << "First Name:" << getFirstName(); std::cout << "Last Name:" << getLastName(); std::cout << "Email Address:" << getEmailAddress(); std::cout << "Age:" << getAge(); std::cout << "Days In Course:" << getDaysInCourse(); std::cout << "Degree Program:" << getDegreeProgram(); }; degree.h #pragma once #include <iostream> enum DegreeProgram { SECURITY, NETWORK, SOFTWARE }; roster.h #pragma once #include <iostream> #include "student.h" #include "degree.h" using std::string; int amountOfStudents = 5; class Roster { static const int amountOfStudents = 5; public: Roster(); //null pointer doesn't have to point to an object, just acts as a placeholder that will be replaced later string* classRosterArray[amountOfStudents]; void classRosterParse(string studentData); void printAll(); void printDegree(DegreeProgram degreeProgram); void printInvalidEmail(); void printAverageDaysInCourse(string studentID); void addStudentData(string studentID, string firstName, string lastName, string emailAddress, int age, int daysInCourse1, int daysInCourse2, int daysInCourse3, DegreeProgram degreeProgram); void removeStudentData(string studentID); }; main.cpp #include <iostream> #include "degree.h" #include "student.h" #include "roster.h" using namespace std; int main() { const string studentData[] = { "A1,John,Smith,John1989@gm ail.com,20,30,35,40,SECURITY", "A2,Suzan,Erickson,Erickson_1990@gmailcom,19,50,30,40,NETWORK", "A3,Jack,Napoli,The_lawyer99yahoo.com,19,20,40,33,SOFTWARE", "A4,Erin,Black,Erin.black@comcast.net,22,50,58,40,SECURITY", "A5,Trenton,Hallman,Trentonhallman@gmail.cosm,19,30,35,52,SOFTWARE" }; Roster classRoster; { //classRoster.printAll(); //for (int i = 0; i < amountOfStudents; i++) { // classRosterParse(string studentData).studentData[i]; //}; }; return 0; }
string* classRosterArray[amountOfStudents]; classRosterArray is an array of pointers to string classRosterArray[i]->print(); std:: string doesn't have a member called `print`
40
cpp_questions
umyimx
You know how people especially some young people say the dislike modern music/society/style. Were there people who felt the same or because they didn't have internet to compare it to anything they never really felt to complain about it.
Interesting question. I was a kid in the 70s Adolescent in the 80s College in the 90s Looking back it never occurred to me the living in the 90s was a blessing and a great time to be alive. At the same time, I was also too young to know if the 80s and 70s were good or bad. I was a kid…you just rode your skateboard and saved paper route money for the new Dead Kennedys record. Life was simple; but I wasn’t an adult with adult perspectives. Looking back…would you relive the 90s? Abso-fucking-loutley
180
AskOldPeople
umyimx
You know how people especially some young people say the dislike modern music/society/style. Were there people who felt the same or because they didn't have internet to compare it to anything they never really felt to complain about it.
In the 80s I and all my peers thought America, and specifically its youth culture, was as shallow and dumb as it could possibly get. We looked back on the 60s with nostalgia.
180
AskOldPeople
umyimx
You know how people especially some young people say the dislike modern music/society/style. Were there people who felt the same or because they didn't have internet to compare it to anything they never really felt to complain about it.
There was plenty to dislike about both decades, but particularly the 1970s, what with Vietnam, Watergate, stagflation, the oil crisis, high unemployment, high inflation, cities cutting services, high crime -- it was bad. The early 1980s was more of the same, then the economy recovered but we still had the crack epidemic and the AIDS crisis. Plus the whole country took a sharp turn to the right. Many of the problems of today -- climate change, income disparity, conservative judges, Evangelical Christian control over the Republicans, fear of minorities, militarization of the police, deregulation, abandonment of antitrust law, betrayal of the unions, worship of billionaires -- started in the 1980s. Heck, young Donald Trump began his self-mythologizing in the 1980s. He built Trump Tower in 1983, using his father's political connections to get the project approved.
110
AskOldPeople
umyxn9
When traveling internationally, when do you decide to exchange your money? Before your trip or after arriving at your destination?
In my case, always after arrival. Get a Schwab high yield checking account. Use it to withdraw cash at the ATM in your destination country. Schwab will reimburse most ATM and conversion fees. So much more cost-effective than getting foreign money from your bank stateside, or at a foreign currency exchange abroad. Heck, even using your debit card from your regular bank is still more cost-effective than walking into your bank or using an exchange kiosk. But you probably won't get your ATM fees reimbursed like with Schwab.
990
AskAnAmerican
umyxn9
When traveling internationally, when do you decide to exchange your money? Before your trip or after arriving at your destination?
I get the local currency from an ATM there. Pulling directly from the ATM gives you the best exchange rate Edit: a few more tips -exchange desks/kiosks will always have a worse conversion rate than the ATM so they can make money, ATMs will use the true rate -get a debit card that reimburses ATM fees, mine does $20 a month so I rarely pay these when traveling -bring some USD with you that can be converted at an exchange just in case you can't immediately get to an ATM but this should be your reserve -get a credit card with no foreign transaction fees and pay with this as much as you can. In my experience Visa > Mastercard > Amex in terms of what is accepted more abroad -whenever you pay with card, always choose to pay in the local currency. Similar to using the ATM, when you pay in the local currency the bank will do the conversion to USD using the true rate. If you choose to pay in USD, the vendor gets to decide what the conversion rate is (usually says on the machine) and it will almost always be worse than the true rate
780
AskAnAmerican
umyxn9
When traveling internationally, when do you decide to exchange your money? Before your trip or after arriving at your destination?
[deleted]
610
AskAnAmerican
un1nhe
https://mars.nasa.gov/raw_images/1064629/ Picture that has people already racing to conclusions about Aliens.
This looks like a chunk of rock has weathered/fallen out between the intersection of two [joints](https://en.wikipedia.org/wiki/Joint_%28geology%29), i.e., two Mode I (extensional) fractures. If you look at the point at the top of the "door" and then beyond onto the outcrop surface above it, you can see the continuation of these fractures (and where they intersect along that weathered surface, further back into the image). Joints are extremely common on Earth and form through a variety of mechanisms. If they are joints as opposed to shear fractures (i.e., Mode II or Mode III, it's hard to tell from a photo like this, but I'd still bet joints though in reality, a conjugate set of shear fractures would give you the same end result), the expectation is that they would form parallel to the direction of maximum stress and in a condition where tensile fractures are possible. This typically means either that they form in the very shallow subsurface (where confining pressure is low enough to not preclude fractures forming in the tensile regime) or in the presence of sufficiently high pore fluid pressure to allow tensile fractures to still form (for any of you [Mohr circle](https://en.wikipedia.org/wiki/Mohr's_circle) fans out there, this implies that the pore fluid pressure is sufficient to shift the minimum principal stress into the tensile regime but that differential stress is still low enough to intersect the failure envelope in the tensile regime). It's also extremely common for multiple sets (where a set implies a group of semi-evenly spaced joints with a common orientation) of joints to form and for blocks of rock defined by these intersections to weather out of an outcrop surface, leaving behind angular crevices, not unlike this feature. So yeah, there are probably millions upon millions of similar rock faces on Earth that if photographed from a particular angle with the light right conditions would appear to form a "door way" like this.
750
AskScience
un21dy
I really look forward to that.
Some time after it is implemented in the three most common compilers.
290
cpp_questions
un21dy
I really look forward to that.
When the STL is standardized as a module so probably sometime after C++23
170
cpp_questions
un21dy
I really look forward to that.
Don't know but I really like them, I hope they become more popular soon.
30
cpp_questions
un40af
How does fruit bats actually transmit diseases to us ? Because we won't know whether the fruits in our supermarkets are bitten by bats, but we still eat them carelessly. But whether there is a nipah outbreak people in some communities blame nearby bats and start killing bats. Can we really blame bats or is deforestation/ pig farms the cause?
It’s a little bit of all these things. Nipah is naturally found in fruit bats, they’re the reservoir species. It could potentially spread to pigs if a pig were to eat fruit that an infected bat had bitten or had other body fluids on. From there it could spread to other pigs and people. Deforestation brings wildlife into closer contact with people and makes these spillover events more likely. The bats have likely been living with it for a long time, it’s just that we’re having more wildlife contact as we remove their habitat. If you’re interested in this sort of thing, I highly recommend the book, Spillover. It’s all about diseases that jump from species to species.
110
AskScience
un4pau
Hey guys I am a big fan of multilingual learning and I am willing to become a translator in the U.S cuz I heard translator is not paid badly there.(btw I am computer science student) If everything goes well I will choose writer/cartoonist as my avocation also.
You will do best in the medical field, but you will have to do a bit of schooling for it. You have to learn a lot of medical terms in both languages and take tests, but I'm sure it's a rewarding job. I loved working with the translators.
140
AskAnAmerican
un4pau
Hey guys I am a big fan of multilingual learning and I am willing to become a translator in the U.S cuz I heard translator is not paid badly there.(btw I am computer science student) If everything goes well I will choose writer/cartoonist as my avocation also.
Translation pay is directly tied to your qualifications. For example, translating legal contracts, patents, medical research, etc. pays one hell of a lot more than virtually everything else (entertainment, packaging, instruction manuals, and the like). To get translation jobs in such fields, however, you generally need to be a good writer in the target language plus have specific knowledge in the domain in demand. If you really want to go down this path the best option is to build experience in house at a large firm or government agency that has a need for a specific type of translation that you are qualified or willing to learn about, and then build up your profile and eventually go freelance. One good source on all this is [Nataly Kelly of Hubspot](https://borntobeglobal.com/).
70
AskAnAmerican
un4pau
Hey guys I am a big fan of multilingual learning and I am willing to become a translator in the U.S cuz I heard translator is not paid badly there.(btw I am computer science student) If everything goes well I will choose writer/cartoonist as my avocation also.
I literally have no context for how the translation field works, how well translators get paid, or how much demand there is for English to Mandarin translation.
30
AskAnAmerican
un4qt1
I’m currently Uk based, and am open to the idea of moving abroad to expand my life and work horizons. I have been warned by my colleagues that the work/life balance is terrible for my counter parts in in America. At the moment, I work 38 hour weeks, and I am not expected to work overtime. I have 30 paid vacation days off. Including an additional week for Christmas, and around 8 bonus bank holidays scattered thou out the year. How does this compare to my counterparts on your side of the pond?
"STEM" is such a wide range of careers it's impossible to answer on that basis. My wife and I both work in STEM fields and our jobs are extremely different. The only thing I notice is that you have a few more vacation days. I have 15 days PTO, 5 sick days, plus our 11 federal holidays off. My wife has been with her company longer so she gets 5 extra. But I work 100% from home, 40 hours a week. In reality I spend about half that time actually working. Can't get more balanced than that.
150
AskAnAmerican
un4qt1
I’m currently Uk based, and am open to the idea of moving abroad to expand my life and work horizons. I have been warned by my colleagues that the work/life balance is terrible for my counter parts in in America. At the moment, I work 38 hour weeks, and I am not expected to work overtime. I have 30 paid vacation days off. Including an additional week for Christmas, and around 8 bonus bank holidays scattered thou out the year. How does this compare to my counterparts on your side of the pond?
In general the work life balance is better in the UK but our pay is higher. It's largely going to be dependent on your job and where you work though.
100
AskAnAmerican
un4qt1
I’m currently Uk based, and am open to the idea of moving abroad to expand my life and work horizons. I have been warned by my colleagues that the work/life balance is terrible for my counter parts in in America. At the moment, I work 38 hour weeks, and I am not expected to work overtime. I have 30 paid vacation days off. Including an additional week for Christmas, and around 8 bonus bank holidays scattered thou out the year. How does this compare to my counterparts on your side of the pond?
You're not going to notice any major differences. Did your colleagues see that in a movie? I don't know where people get this stuff. As long as you're not working somewhere for the glamour of it and you have the ability to separate yourself from your work, you'll be fine. You're probably not going to get 30 days + 1 week of vacation, but you'll probably also only be putting in 30 hours of real work a week in an office job, if that.
90
AskAnAmerican