I want to add 30 days to today date and here how i tried Thanks in advance!  var date = new Date();     document.getElementById("demo").value = (date.getMonth() + 1) + '/' + date.getDate() + '/' + date.getFullYear();
How to add days to current Date using JavaScript. Does JavaScript have a built in function like .Net's AddDay?
I would like to see a breakdown of reputation by post type on the user summary page.    This would help show, at a glance, how much someone actually knows vs. how good they are at asking questions.  For instance:     Reputation from Questions - 10,015 from 1024 posts   Reputation from Answers - 110 from 11 posts   Reputation from Edits - 400 from 1000 edits     I would take any answers the above person gave me with a grain of salt instead of assuming they were knowledgeable because they have 10k rep.  We already have a multitude of other readouts on the new page, so this shouldn't up the clutter factor too much either. Could the change from an edit be displayed in a side-by-side display Have red shifted photons lost energy and where did it go? I think the title says it. Did expansion of the universe steal the energy somehow? Yes, it's time for me to complain about plagiarism again.  We already have Suggested Edit audits, but I would like to see Tag Wiki and Tag Wiki Excerpt audits that specifically introduce copied content for that tag without including the appropriate source(s), and warn people who approve it that they just approved a tag with plagiarized text.  For example, an audit for the  tag could be:     Microsoft SQL Server is a relational database management system developed by Microsoft. As a database, it is a software product whose primary function is to store and retrieve data as requested by other software applications, be it those on the same computer or those running on another computer across a network (including the Internet). There are at least a dozen different editions of Microsoft SQL Server aimed at different audiences and for different workloads (ranging from small applications that store and retrieve data on the same computer, to millions of users and computers that access huge amounts of data from the Internet at the same time). Its primary query languages are T-SQL and ANSI SQL.   Anyone who spends 15 seconds Googling this will see where it came from -- the problem is, most people don't.  I know with Suggested Edit Audits, it's just random text to catch the most egregious reviewers; for this, you would have to most likely select a small sample of tags, and then create their copy-and-paste entries for audits.    The whole point of this would be to raise awareness for people who have figured out how to recognize and pass Suggested Edit audits, but still don't understand the finer nuances of reviewing. Prove $\sin^2\theta + \cos^2\theta = 1$ How do you prove the following trigonometric identity: $$ \sin^2\theta+\cos^2\theta=1$$  I'm curious to know of the different ways of proving this depending on different characterizations of sine and cosine. How to make horizontal lists? This might seem like a very simple question, but what is the easiest way to turn a normal vertical list into a horizontal one? I would appreciate if someone could help me write the mathematical equation for the seasonal ARIMA (2,1,0) x (0,2,2) period 12. I'm a little confused with how to go about this. I would prefer an equation involving $Y_t , e_t, θ$ and $Θ$. Confusing article status for journals of American Mathematical Society: "reviewing" AND "being handled by an editor" The web page of my article in the AMS editorial system for some three months says &quot;Article status: Reviewing&quot; and in the next line &quot;Your paper is being handled by an editor&quot;. I find this confusing as the &quot;reviewing&quot; status appears to suggest that the article is with the referee(s) rather than with the editor but this in turn seems to contradict the line &quot;Your paper is being handled by an editor&quot;.  Could someone with enough experience with AMS journals please explain how should one interpret the combination of &quot;Article status: Reviewing&quot; and the line &quot;Your paper is being handled by an editor&quot; at the article page? More broadly, which are the possible article statuses in the AMS editorial system?  Many thanks in advance. How do you convert a numerical number to an Excel column name in C# without using automation getting the value directly from Excel.  Excel 2007 has a possible range of 1 to 16384, which is the number of columns that it supports. The resulting values should be in the form of excel column names, e.g. A, AA, AAA etc. Can we please hold the hats? I really like the hats game. But I would love to keep the hats longer then only one winter. I want to leave them in my wardrobe during summer. Last year, I collected some cool hats, and I apparently lost them during summer.  Maybe we could make a system that allows hats to last for about 2 or 3 years, so we don't have to start over each winter. Or even specify per type of hat a number of years they last? Very very rare hats could last for ever.  I asked this, simply because I love hats! :D Show reference label when it is undefined When a reference is undefined, LaTeX shows simply [??] which doesn't give much information. I would like it to show the label instead. This is useful when more collaborators work on the same preprint and the references are yet to be done.  I'm using neither biblatex nor natbib. I do use bibtex but it is irrelevant for this question.  MWE:  \documentclass{article}  \begin{document}  This: \cite{undef} should look like: [{\bfseries ?? undef}]  \end{document} Where does Google Chrome automatically save pages? I opened the following page:   When disconnecting WiFi and even after rebooting the mobile phone, the page can still be read due to being saved automatically.  Left to the URL bar, an indicator looks like this:  This also shows up when opening manually saved pages, which are saved as MHTML files in the default download folder.  However, an automatically saved page can not be re-downloaded manually to get to the download folder, because the arrow is greyed out.I wish to copy some automatically saved pages into the download folder.  Where are the files of automatically saved pages stored? Self-Studying Measure Theory and Integration As the title says, I'm interested in reading about measure theory and integration theory on my own time, and was hoping for book recommendations, prerequisites, and things like that.  As for my background, I've taken introductory analysis, where we covered the "typical" subjects up until some theorems about differentiable functions.  I'm taking intermediate real analysis now; we talked about metric spaces in general for a while, but lately we've focused solely on $\mathbb{R}^n$. Now we're working towards a proof of the implicit function theorem in $\mathbb{R}^n$.  I haven't learned any of the theory behind Riemann integration, unfortunately. Is it important to be familiar with this first? Are keywords in URLs good SEO or needlessly redundant? A coworker and I are locked in a debate over the value of SEO keywords in the URL of a page. She wants to change all the filenames of the HTML pages of a fencing company so they look like residential-home-chicago.html, contact-chicago-contractor.html, and so on. She is convinced that because Google highlights keywords in URLs in search results, that means that putting keywords here is more valuable.  My position is that these do not improve SEO, since Google doesn't seem to give keywords in the URL any more weight than keywords in the body of the page, and . In the meantime, they make it harder for me to find the pages I want when its time to edit them, and the site as a whole looks cheap and spammy.   suggests to me that yes, keywords in URLs are useful, but not superior, and that they are more useful for human readability than search engine rankings.  I'm looking for authoritative sources that support either position, not blog articles from SEO optimization companies trying to promote themselves. Find $f$ if $$ f(x)+f\left(\frac{1}{1-x}\right)=x $$ I think, that I have to find x that $f(x) = f\left(\frac{1}{1-x}\right)$ I've tried to put x which make $x = \frac{1}{1 - x}$, but this equation has no roots in real numbers. Although many have attempted to explain the difference among \mathrm, \textrm, \textnormal and \text (and others?), I found them misleading.  See for example the LaTeX's Wiki \mathrm explanation   Why is it wrong? Let's try all of them within an article and a beamer and you'll see the difference and, therefore, error.  equation.tex  \begin{eqnarray*}   \int_1^9\! \cos{x} \,\mathrm{d}x &amp; &amp; \textrm{this is textrm}\   \sum_1^9 y                       &amp; &amp; \textsf{this is textsf}\   \prod_1^9 z                      &amp; &amp; \textnormal{this is textnormal}\   \bigcup_1^9 w                    &amp; &amp; \text{and this is just text} \end{eqnarray*}   article.tex  \documentclass{article} \usepackage{amsmath} \usepackage{amsfonts} \usepackage{amssymb}  \begin{document}   \input {equation} \end{document}     And until here everything looks fine...  beamer.tex  \documentclass{beamer} \usepackage{amsmath} \usepackage{amsfonts} \usepackage{amssymb}  \begin{document}   \begin{frame}     \input{equation}   \end{frame} \end{document}     And here we can clearly see that \mathrm does not behave as expected, i.e. does not provide a function aspect to the d. Does anyone know what am I supposed to use here instead? Just \text?? o.O  Moreover, I cannot see any difference between \textnormal and \text.  Finally, \textrm looks useless.. Splitting of prime ideals in algebraic extensions I am using QGIS 3.2.0 on a Mac (and also have QGIS 2), and I have a fishnet grid (probably created in Arc) that comprises of nearly 2 million grid cells. As a result, every change I make to the attribute table takes hours, so I can't experiment as I would usually.  I need to label each grid cell such that the north-westernmost cell is "1", and the numbers proceed by rows, until the last number goes into the south-easternmost cell. Using the row-number doesn't work, as that's not how the table is sorted. I've done this before, but cannot remember how. Disclaimer: I'm pretty novice at sysadmin stuff.  I'm trying to set up port forwarding in an AWS EC2 instance, this has to be done in the command-line because I don't want to go in and edit anything, it has to be automatic (it's part of a build process).   sudo echo "net.ipv4.ip_forward = 1" &gt;&gt; /etc/sysctl.conf      Permission denied   The weird thing is I've been (successfully) using sudo for pretty much every command that required su privileges. If I do sudo su before the command (trying it out by hand in an ssh session), then it works.  Reasons behind this? Possible solutions that don't involve sudo su or manual edits? Comprehensive Rules for Game of Thrones Lines of Succession I'm three quarters through the third book, "Storm of Swords" right now (so please, no spoilers from too late in the book or any subsequent books).  I just read a part where Tyrion is discussing with Prince Oberyn and they mention the difference between Dornish law and Westerosi law in Line of Succession (ie women can rule under Dornish law).  I'm a little confused trying to puzzle out what the exact LOS rules are.  At first I though it was: at the moment a king/lord dies, to find who holds the title next, you do a depth-first search down the family tree starting with the oldest sibling (ignoring anyone who isn't true-born or has given up their claim ie as Night's Watch or Kingsguard etc.).  Then, for Dornish law you take the first living person and for Westerosi law the first living male person found in this way (so succession can pass through a woman in both cases, but only Dornish law actually allows them to claim the title). If there are no valid living heirs, then you work backwards along the paternal line until you find an ancestor who has living heirs and start from them.  But there were various references to if Sansa's brothers were all dead, then her child would claim Winterfell.  It seems to me that that's only true if somebody else doesn't get it first.  In other words, if Sansa's brothers are killed before she has a child (even if she's already married), doesn't that mean Winterfell would pass to the nearest cousin along her father's line (whomever that may be)?  And then because that cousin has already held Winterfell, when they die the next in the line of succession starts from them so Sansa's children's family would not have claim to Winterfell again unless that cousin has no valid heirs.  What am I missing here? Is there some exception?  Are there no valid cousins?