so I'm learning programming and I understand variables, if else statements, cin and cout. So for a starter project I'm just creating a console application that asks the user questions, such as age, location etc. One of them I would like just a simple yes or no answer. I've managed to do this, but what the user inputs must be the same case as the word in the if statement. i.e. if statement contains "Yes" with a capital 'Y'. If the user inputs "yes" without a capital 'Y' then the program fails.  The if statement sees if it is a "Yes", if it is, provides positive feedback. If "No", then it provides negative feedback.  How can I make it no matter whether the answer is "YES", "yes" or even "YeS"?
I want to convert a std::string to lowercase. I am aware of the function tolower(). However, in the past I have had issues with this function and it is hardly ideal anyway as using it with a std::string would require iterating over each character. Is there an alternative which works 100% of the time?
Why doesn't the Enterprise use stealth/invisibility technology like the Romulans and Klingons? The stealth mode of starships plays a huge role in many Star Trek films and episodes and is a strong advantage in combat. I remember an episode revealing that the Federation developed a secret stealth technology (afair on Riker's former ship with another captain appearing in this episode) that even made it possible to fly with the ship through matter.   Nonetheless, while stealth technology seems standard for Romulans, Klingons (Ferengi, Vulcans?) and does not break any intergalactic laws (do these exist at all?), the Federation doesn't use it? Why doesn't Volumetric follow the shape of Mesh in Eevee? So I was in the middle of making a ball-shaped smoke, but the volumetric effect didn't work following the basic shape. It remains cube in Eevee Blender 2.8; while in Cycle it works, but in Cycle it takes thousands of years for Render. My interest in Blender comes from wanting to use it to model physical structures and produce architectural drawings; what I have so far is really impressive, but there doesn't seem to be too much information about my particular interest.   Are there any (Blender-) resources that would be particularly useful for architects? E.g. packages of standard 'elements' like windows, doors, roofs or whatever, or perhaps a discussion group specifically for architects? How do I copy to the clipboard in JavaScript? What is the best way to copy text to the clipboard (multi-browser)? I have tried: function copyToClipboard(text) {     if (window.clipboardData) { // Internet Explorer         window.clipboardData.setData(&quot;Text&quot;, text);     } else {         unsafeWindow.netscape.security.PrivilegeManager.enablePrivilege(&quot;UniversalXPConnect&quot;);         const clipboardHelper = Components.classes[&quot;@mozilla.org/widget/clipboardhelper;1&quot;].getService(Components.interfaces.nsIClipboardHelper);         clipboardHelper.copyString(text);     } }  But in Internet Explorer it gives a syntax error. In Firefox, it says unsafeWindow is not defined. A nice trick without using : Choose information when copying profile do_shortcode() within Admin Page I'm using a few plugins that have shortcodes ... however, instead of creating a public page for the content, I've created some new pages within the admin using add_menu_page and I need to know how to utilize do_shortcode() within this context.  As it stands, all the function does it spit out the string. I'm assuming it's because the shortcode API isn't available within an admin page.  How do I get around this? There is no documentation that I can find that explains how to utilize shortcodes within the WP Admin... or if it's even possible.    Specifically I'm trying to utilize WooCommerce shortcodes within the WP Admin. I hate the fact that plugins don't utilize the WP Backend for account/user management. I know that a stationary metric is one which possesses a timelike Killing Vector (so I have time invariance).  I read that a static metric is one which has a timelike Killing vector (so it is stationary) AND this Killing vector is orthogonal to a family of hypersurface (of dimension n-1 is n is the dimension of my manifold). I don't understand the "physical" meaning behind this definition ? Is there a way to explain this in some more intuitive way ? Thanks Let $f$ be a real valued and continuous function over $[a,b]$ with $a &lt;b$ such that $f(a)=f(b)$ , My question here is :     Question (claim): How to show that : there  exists  $c \in [a, \frac{a+b}{2} ]$ such that : $f(c)=f(c+\frac{b-a}{2})$.   Note: I have tried intermediate values but I didn't succeed. Fuzzy string search library in Java %AX = (%AH + %AL)  So why not %EAX = (%SOME_REGISTER + %AX) for some register %SOME_REGISTER? How and when did American spelling supersede British spelling in the US? Why do all the planets of the solar system orbit in roughly the same 2D plane? Most images you see of the solar system are 2D and all planets orbit in the same plane. In a 3D view, are really all planets orbiting in similar planes? Is there a reason for this? I'd expect that the orbits distributed all around the sun, in 3D. Has an object made by man (a probe) ever left the Solar System? How strongly can a 1mo be rocked? My 1 month old baby only seems to quiet down when I vigorously rock her (while I carefully hold her head). Can I cause her some (brain?) damage if I rock her too hard? I'm running Fedora 25 and I need to take a few particular screen captures so I've read that shutter is a great tool for that. Sadly I am unable to use it for some reason. Whenever I try to take a screenshot this is the result: I have been reading for days about how to remove the Google Search Bar from the top of my Nexus 6 since I never use it. I have gotten mixed answers on exactly what file to delete and where it is.  I have heard quicksearchbar.apk but it's not in /system/app like in previous versions. Does anybody know where the file/files are I need to delete in order to get rid of the search bar, or else, how to remove it? Preferably not downloading another launcher, since I don't want to bloat my phone when I could reduce the size. Why does the Moon not revolve around the Sun directly? The sun pulls on the moon with a force that is more than twice the magnitude of the force with which the earth attracts the moon. Why, then, doesn’t the sun take the moon away from the earth? Showing that $\mathbb{Q}[\sqrt{2}, \sqrt{3}]$ contains multiplicative inverses Why must $\mathbb{Q}[\sqrt{2}, \sqrt{3}]$ -- the set of all polynomials in $\sqrt{2}$ and $\sqrt{3}$ with rational coefficients  -- contain multiplicative inverses?   I have gathered that every element of $\mathbb{Q}[\sqrt{2}, \sqrt{3}]$ takes form $a + b\sqrt{2} + c\sqrt{3} + d\sqrt{2}\sqrt{3}$ for some $a,b,c,d \in \mathbb{Q}$, and I have shown that $\mathbb{Q}[\sqrt{2}]$ and $\mathbb{Q}[\sqrt{3}]$ are both fields, but it's not clear to me why this allows for general multiplicative inverses to exist in $\mathbb{Q}[\sqrt{2}, \sqrt{3}]$. Number of ways in which $5$ boys and $5$ girls are ordered in such a way that exactly $4$ girls stand consecutively in the queue Let $n$ be the number of ways in which $5$ boys and $5$ girls can stand in a queue in such a way that all the girls stand consecutively in the queue. Let $m$ be the number of ways in which $5$ boys and $5$ girls in such a way that exactly $4$ girls stand consecutively in the queue. Then find $\frac{m}{n}$.    I could find $n$ correctly as $6!\times 5!$, but I am finding $m$ as $7!\times 4!\times \binom{5}{1}$, but the book says $m$ is $6!\times 4!\times 5\times \binom{5}{4}$. Where have I gone wrong? What is the proper logic to find $m$? How to rig a shirt with buttons so that the buttons follow the mesh of the shirt I didn't address this in a while because I was busy with something else, but now it has cycled back into my schedule.  Right now I have a shirt modeled and bones set in place. It's already technically rigged, but the only issue is the buttons.   I'm not entirely sure how to go about connecting them to the shirt's deformations. I tried to combine them and the shirt into one object, but because of the shirt's modifiers, (Solidify and subsurf, which I don't want to apply yet), the buttons become extremely deformed. I've tried to match the weight painting intensity where a button is at in correspondence with the shirt, but that doesn't seem to work, maybe it has to do with the specifics of where the button is?   Is there a way to make the buttons follow the shirt's deformations without deforming the mesh vertices of the button? I know that if I probably apply the modifiers on the shirt and combine it with the buttons, it would be okay, but I'm not okay with doing that just yet with the shirt.    I rigged the shirt by deleting all vertex groups, assigning empty groups to the mesh from the armature, and then assigned automatic groups in the weight paint menu.  Is there a way to do this? group of units in a topological ring