We have an organization that has a  (discourse), a  (ghost CMS), (learning platform) and etc. They all share a similar navigation with the organization's logo in the middle and relevant navigational items. Currently the logo on each platform links to the homepage of the currently visited platform. I was wondering if changing the link of the logo to / (that has a pitch and cta to sign up) across platforms would cause confusion for the users. What would be the best logo links/navigation strategy for sites with multiple platforms?

lets say you have a site called "example.com", which is the homepage of a company that provides a login for its customers and different functions like a personal backoffice, learning material and company related stuff like news, about etc.  One of the things that site contains is a link to a sub-domain which basically is a media-area for the customers where they can watch videos from different topics that are related to their daily work, when the user clicks on that link, the sub-domain (lets call it videos.example.com) opens in a new tab.   What the project manager suggested  He wanted to add a home-icon next to the company logo on the left of the head-area, the company logo should act as a link to "example.com" the home icon should link back to "videos.example.com".  In my opinion thats to confusing for the user, since we are currently using a home-icon on "example.com" as a link back to the starting-page, users might expect that the home-icon will take them back to "example.com" instead of "videos.example.com", also most users click on the logo to jump back to the starting page, which makes it even more confusing.  I said we should not place them next to each other, we should only use the logo instead of a home-icon to take the user back to the starting page.  I still want to provide the users a way to get "back" to "example.com", and now i am looking for a good, understandable way how to do this.  Do you have any proposals on how to make that as transparent as possible?  Btw. the header will consist of Logo + 5 navigation points + search bar + login option


I saw an old B&W sci fi movie involving several crew members of a space ship who have been turned to stone\petrified. When another crew member ventures outside to investigate there is a big sphere outside the ship which draws him inside against his will.  I don't remember if the sphere used tentacles or some invisible force.

I'm trying to remember an old movie title from when I was a kid. I have not been able to get any information. The movie is pre 1980. Is in another planet (maybe Mars, not sure) and there are this creatures that were thin with more than two arms, all ending in disk. If a person looked at them, the aliens will shine a light that will kill you (you will get your eyes burn or a black circle around the eyes). After you die an egg shaped structure will open and drag you inside.


Sauron seems to have quite a bit of power while he does not have the Ring. What does the One Ring in his possession allow him to do that he cannot without it?   He still controls thousands of orcs, the ringwraiths and other creatures to do his dirty work while not having the One Ring. From what I understand, Sauron needs the One Ring back in order to be able to gain control over Middle-earth and its people. What is the reason for this? He was still able to be destroyed when he had the ring, simply by having it cut from his hand.  Is it the fact that his powers greatly increase while having the ring, and if so, what are those powers that increase?

Why would Sauron make himself a ring that he invested most of his power in? Wouldn't it be better to keep the power in his physical form and not risk leaving his power in a physical form that could be stolen (which did happen when Isildur took it). Because of its being in the form of a ring, its power could be abused by someone else to attack him.


I'm trying to run an update cursor. Usually if I have an issue with databases with enterprise connections, making a connection file clears it up. This time when I tried to execute my code I just get a Runtime Error: cannot open workspace message.   I went ahead and changed the version but that didn't work either. I also tried using the workspace without the connection file and I got the same error. I've yet to make it past edit = arcpy.da.Editor(workspace)  Here's the bulk of my immaculate code:  def build_connection_file():     """This function handles everything involved in building a connection file to the feature class"""      directory = r"C:\TempConnectionFiles"     if not os.path.isdir(directory):         os.path.makedirs(directory)      feature_dataset = r"ThisIsReal"     feature_class = r"ThisIsReal"      sde = r"Database Connections\Real.sde"      versions = [version.name for version in arcpy.da.ListVersions(sde)\                 if (getpass.getuser() in version.name)]      print versions[-1]      connection_name = "ThisIsReal.sde"     if not os.path.isfile(os.path.join(directory, connection_name)):         arcpy.CreateDatabaseConnection_management(             out_folder_path = directory,             out_name = connection_name,             database_platform = "real_platform",             instance = "real_instance",             account_authentication = "OPERATING_SYSTEM_AUTH",             username = "",             password = "",             save_user_pass = "DO_NOT_SAVE_USERNAME",             database = "real_database",             version_type = "TRANSACTIONAL",             version = versions[-1])      connection_feature_class_full = os.path.join(         directory, connection_name, feature_dataset,         feature_class)      print connection_feature_class_full      #this was required last time I did this.     table_view = arcpy.MakeTableView_management(         in_table = connection_feature_class_full,         out_view = r"connection_table", where_clause = "",         workspace ="", field_info = "")      arcpy.ChangeVersion_management(         in_features = table_view, version_type = "TRANSACTIONAL",         version_name = versions[-1], date = '')      print("changed version")      return connection_feature_class_full  connection_feature_class = build_connection_file() edit = arcpy.da.Editor(connection_feature_class_full) edit.startEditing(True, False) edit.startOperation()   Is there a setting in my database that could be responsible for this? Is there something wrong with my code?

I used python add in to make a tool bar in Arcmap that edits features on a map. It works on a file geodatabase, but not on an ArcSDE version one. I've been getting an FDO error: 0. The solutions that I've found all involve opening a workspace, but I'm getting an error doing that as well. Here is the relevant portion of my code:          outFolderPath = r"U:\tempStuff"         outName = "Stuff.sde"         databasePlatform = "SQL_Server"         instance = "SQL Server"         arcpy.CreateDatabaseConnection_management(outFolderPath, outName,                                                   databasePlatform,                                                   instance)         print "Centroid of buidling:(%r,%r) Side length: %r" % (xCoordinate,                                                                 yCoordinate,                                                                 bob)         print "workspace is %r" % outName #outName is workspace          #Start edit session with an undo/redo stack then start         #edit operation         print "Starting editing"         edit = arcpy.da.Editor(outName) #outName is workspace Line 86         edit.startEditing(True, True)         edit.startOperation()          #stuff happens          cursor = arcpy.da.InsertCursor( fc, ["SHAPE@"])         cursor.insertRow([stuff])             #stop the edit operation and then save changes         edit.stopOperation()         edit.stopEditing(True)          del cursor         print "Building should be drawn"   This is the exact error I've been getting:  Traceback (most recent call last):   File "C:\Users\153289\AppData\Local\ESRI\Desktop10.3\AssemblyCache\{0BEF4E61-6332-4BCA-A908-959CA3C0B4E7}\leetScripts_addin.py", line 86, in onClick     edit = arcpy.da.Editor(outName)#outName is workspace RuntimeError: cannot open workspace   What's am I doing wrong in my code?


I am beginning to study probability and I found the following problem:  What is the probability of to get a number twice after two throwings?  The answer was that since we have six distinct results in a fair die every possible result has $1/6$ of probability of happen and since that the result is:  $$ P(\text{rolling the same number twice in a row on a fair die} ) = (1/6)(1/6).$$  I understand till the part of the probabilities, I know that since every event is independent of the other we are applying the multiplication rule, However I would like to go more deep in the analysis and not to take this as a strict rule, I would like to understand why we had to multiply the numbers, I mean why not to sum them or divide?, I need to understand why the rule of multiplication works, I would like to receive a empirical or formal explanation of this result in order to understand more, thanks for the support.  I would like to state that my question is different since I know that if I have the scenario of only one die, thrown out in two different times my result is correct but I don't understand why we have to multiply the probabilities I know that we are using the multiplication rule but why it works? what is the reason to multiply the numbers I mean why not to divide it or to sum it, I would like to go more deep in the analysis.

So I know that rolling a fair six-sided die twice would mean the total possible outcomes would be 36, and rolling the same number twice would be 2/36 or 1/18, but I feel like that's wrong. What am I doing that isn't right?


I was working on a project while I came across a strange problem. here is my code let newEvent = event; console.log(changes, event, newEvent); newEvent.title = changes.title; newEvent.description = changes.description; console.log(changes, event, newEvent);  The first console.log outputted:  {title: 'Event 2', description: 'blaat'} {title: 'Event 1', description: ''} {title: 'Event 1', description: ''}  and this is what I expected, but what is didn't expect was the next console.log which outputted:  {title: 'Event 2', description: 'blaat'} {title: 'Event 2', description: 'blaat'} {title: 'Event 2', description: 'blaat'}  I expected the following output:  {title: 'Event 2', description: 'blaat'} {title: 'Event 1', description: ''} {title: 'Event 2', description: 'blaat'}  Is there anybody that can help me whit this problem, thanks id advance

The primitive types (number, string, etc.) are passed by value, but objects are unknown, because they can be both passed-by-value (in case we consider that a variable holding an object is in fact a reference to the object) and passed-by-reference (when we consider that the variable to the object holds the object itself).  Although it doesn't really matter at the end, I want to know what is the correct way to present the arguments passing conventions. Is there an excerpt from JavaScript specification, which defines what should be the semantics regarding this?


I am studying as a full-time student in Latvia. We have already booked our flights for Christmas to Germany between December 21 and January 4. But the Latvian government prolonged my application for a residence permit.  Therefore, I do not have a residence permit right now, but I have a paper that says I can stay in Latvia until February 14 (Document written in Latvian). I was wondering if I can fly to Germany and come back to Latvia with my expired visa by plane.  It would be a disappointing Christmas for us if I could not be there.  I am waiting for your answers, thanks.  I am a Turkish citizen.

I googled all over and couldn't find a definitive answer on this. I arrived to Poland on a Schengen visa and applied for a temporary residence permit on my 88th day in the Schengen area. I got my passport stamped saying that I applied and am waiting for that permit. While it is being processed, can I travel to other Schengen countries? My visa is still valid, but what about the 90/180 rule?


Is there a way I can get LaTeX to output a .bib file containing only the citations actually in my document? I often copy and past over old .bib files, which makes them rather unweildy over time. Is there any way to get tex to run, and then instead of giving me a pdf, it gives me a new .bib with only the citations actually used in the document I've run it on?

My colleague asked me to write a page for a paper he writes. I wrote the page in LyX, compiled it to LaTeX, and sent him the TeX files. Then he reminded me that I forgot to send the .bib file with all the references.  But, my .bib file is huge - it contains over 1000 references (I have a global BiBTeX file for all my papers). The page I wrote uses only about 20 of them.  Is there an automatic way to extract from the bib file, only the records relevant to the current paper?


This StackExchange  attempts to get the first 10 unanswered bounty questions: SELECT TOP 10 Posts.AnswerCount, Posts.AcceptedAnswerId, Posts.Id AS [Post Link] FROM Posts     JOIN Votes ON Votes.PostId = Posts.Id       and Posts.PostTypeId = 1 -- questions       and Votes.BountyAmount > 0       and Posts.AnswerCount = 0       and Posts.AcceptedAnswerId IS NULL ORDER BY Posts.CreationDate DESC  ...but it returns a list of questions that already have accepted answers:  I would've expected AnswerCount and AcceptedAnswerId to be nonzero for those answered questions. Why are these posts showing up in my results? (I think it's a bug, but maybe my query is wrong.)

When I use , the results I get don't reflect recent activity. Sometimes the data I get back are two months out of date. What's wrong? This is intended to be a canonical reference for questions about SEDE not reflecting real-time results.


I'm trying to return MySQL rows when the start_date and end_date period falls within a date range, either completely or partially.  Here's the SQL I'm using at the moment.  SELECT         start_date,         end_date,         id     FROM         employee_leave     WHERE         DATE(start_date) >= :start_date_range     AND DATE(end_date) <= :end_date_range;   This works fine to return rows that fall wholly within the specified range but it needs to also return rows that are partially within the range too.  Example, start_date_range = 2015-07-04 end_date_range   = 2015-07-15  If I have the following rows they should all be returned:   start_date = 2015-07-05, end_date = 2015-07-10 start_date = 2015-07-01, end_date = 2015-07-10 start_date = 2015-07-01, end_date = 2015-07-20 start_date = 2015-07-11, end_date = 2015-07-20

Given two date ranges, what is the simplest or most efficient way to determine whether the two date ranges overlap?  As an example, suppose we have ranges denoted by DateTime variables StartDate1 to EndDate1 and StartDate2 to EndDate2.


Any help would be appreciated. I have a table presenting multiple r correlations between various formats of the same test and the construct/dimensions it purports to measure. Is there an acceptable way in which to calculate an average correlation of all the constructs/dimensions related to one format of the test please?

Let's say I test how variable Y depends on variable X under different experimental conditions and obtain the following graph:    The dash lines in the graph above represent linear regression for each data series (experimental setup) and the numbers in the legend denote the Pearson correlation of each data series.  I would like to calculate the "average correlation" (or "mean correlation") between X and Y. May I simply average the r values? What about the "average determination criterion", $R^2$? Should I calculate the average r and than take the square of that value or should I compute the average of individual $R^2$'s?


I needed to reinstall wine from scratch so I first decided to uninstall the current version but, running the command  sudo apt-cache pkgnames wine   before and after running any of:   sudo apt-cache --purge remove wine1.4 sudo apt-cache --purge remove wine1.6 sudo apt-cache --purge remove wine1.7   results in the same lists of packages, so how do i know that executing apt-cache remove actually has uninstalled the package I commanded?  also should'nt the --purge option imply complete removal of wine (including wine1.7-dbg, wine1.7dev and several other files)?

I am trying to do a clean install of the octave3.2 package.   To do this, I removed it, then tried to reinstall it.   When I reinstalled, an error occurred. It could be a bug in the package, but I want to make sure I have everything removed so that I can do a clean install.  Is it enough to do this?  sudo apt-get --purge remove octave3.2


What should be my course of actions when elected moderators (specifically "Stack Overflow in Russian") unjustifiably lock and close questions on the Meta? I realize, that deciding what is justified and what is not might be my personal opinion, but this is why I'm in need for a higher authority here. I have checked through the "Contact us" but could not find a relevant topic. I'm also not eager to use the ruSO "Contact Us" form, since it is likely leading to the same moderators who mistreated the rules in the first place.  For anyone interested, here's the ruSO topic on the matter, from which I'm trying to escalate the issue: . TLDR in Eng: Question #1 () goes like "Why does ruSO supports these offtopic competition-like questions which do not have a clear rules set and are largely violating SO policy on questions guidelines" - was closed as "Offtopic" itself (ironically). Not looking at the issue presented - it is clearly a wrong moderator action, to lock the question on Meta that is aimed at discussing the rules and finding a right solution - that's one of the Meta goals after all. Question #2 () goes like "Why is ontopic question was locked as offtopic?" - was closed as "Duplicate of the above question". Now this is wrong once again - these are different questions, but the moderators acted nonetheless. I have casted my "re-open" vote, of course. P.S. Let me know if I have missed something or need more details to add.

One or more of the following things happened to me on a Stack Exchange site:   My post(s) were wrongly deleted or locked by a moderator A moderator posted a wrong comment on one of my posts I was suspended, but did not do anything wrong I asked a meta question, but the question was closed and/or deleted A moderator discredited me in public ...   I think a moderator has abused their power, but I feel powerless against them.  What recourse do I have now? What can I do when I feel that a moderator has abused their power, and has been repeatedly unfair in their dealings with me?


What is the relation with this user www-data and web server like apache2?

I'm working through . At the end of the "Create a systemd Unit File for uWSGI" in the article they discuss the www-data user.  What is this and why is it important?


I am going to start a new 5e campaign, nobody having played it before.  I was asked whether it would be sensible to take the War Caster feat and stumbled over the problem of whether its opportunity attack is made with disadvantage.  Since, as far as I am aware, a creature trying to leave the reach of a PC is the only way to trigger an opportunity attack, any magic opportunity attack that requires an attack roll would be while the target creature is still in 5ft and conscious, and therefore be made at a disadvantage.  Is my reading of the rules correct? If not, what did I miss?

An opportunity attack is described this way (PHB, p. 195):     You can make an opportunity attack when a hostile creature that you can see moves out of your reach. To make the opportunity attack, you use your reaction to make one melee attack against the provoking creature.   The last benefit of the War Caster feat says (PHB, p. 170):        When a hostile creature’s movement provokes an opportunity attack from you, you can use your reaction to cast a spell at the creature, rather than making an opportunity attack. The spell must have a casting time of 1 action and must target only that creature.      Without the Crossbow Expert feat, all ranged attacks (including ranged spell attacks) made when an enemy is adjacent suffer this penalty (PHB, p. 195):     You have disadvantage on a ranged attack roll if you are within 5 feet of a hostile creature that can see you and that isn’t incapacitated.   As an opportunity attack normally grants a melee attack, does it seem reasonable to assume that the target remains at melee range for the spell attack granted by War Caster? If so, does this require ranged spell attack rolls to be made with disadvantage?  The trigger for an OA is a creature moving "out of your reach". This suggests to me that the creature is out of the 5' disadvantage zone, but it seems like that would preclude making a melee spell attack.  Do characters with the War Caster feat get the best of both worlds: being  allowed to make either a melee spell attack or a non-disadvantaged ranged spell attack?


How can I clear the screen from former results in python cmd? I want to clear the screen in each level of a loop, I mean how to clear the results and print the new one instead of that?

Like most Python developers, I typically keep a console window open with the Python interpreter running to test commands, dir() stuff, help() stuff, etc.  Like any console, after a while the visible backlog of past commands and prints gets to be cluttered, and sometimes confusing when re-running the same command several times.  I'm wondering if, and how, to clear the Python interpreter console.  I've heard about doing a system call and either calling cls on Windows or clear on Linux, but I was hoping there was something I could command the interpreter itself to do.  Note: I'm running on Windows, so Ctrl+L doesn't work.


Let $p(x)$ be an eighth degree polynomial. Given that:  $p(1) = 1$, $p(2) = 1/2$, $p(3) = 1/3$, .... $p(9) = 1/9$  Find the value of $p(10)$. I tried to approach this by taking $h(x) = p(x) - 1/x$ but then $h(x)$ won't be a polynomial. I tried to manipulate the equation but I failed to find anything helpful. I have found a relation between the coefficients and some values; 9 equations and 9 variables but it would be too cumbersome to solve.   Some guidance would be appreciated. Thanks! (Sorry for the poor title; if anyone can improve it please do so)

Suppose $P(x)$ is a polynomial of degree $2012$ and $P(x) = 1/x$ when $x$ takes the integer values $1\cdots2013$ (inclusive). What is the value of $P(2014)$?   I get $1/1007$ but I'm not sure if it's right, and my method is very inelegant.


I have a Kill-A-Watt Power meter on my computer that has a GPU mining bitcoins. It draws 500W from the wall outlet.  My question is, is my computer outputting any less heat than an equivalent 500W heater? Or is 100% of the power drawn from the wall converted into heat?  I'm not sure where the energy would go, so my gut reaction seems to say yes. However, the computer is performing other operations with the power, flipping transistors and spinning fans and such. Would it have some less-than-100%-percentage of the power input that is converted to heat then?  If the fans and hard drives and other kinetic components were excluded (say 500W with nothing spinning, all solid state), would it then have the equivalent heat output of the 500W heater or a perfect 500W heat source?

I am trying to find a good rough guesstimate of how much of the maximum wattage usage of a graphics card is turned into hot air.  Say a graphics card is rated at using X watts at maximum usage. How much of that is released as heat into the air via the cooling setup, and how much is not (If not where does it go? To ground?)  Yes I know there are a lot of variables here, I am just looking for a guesstimate from someone who would understand better than me. I'm specifically using  (Radeon 6990 375 watts max)


Suppose an abstract class who has all three methods in it and all are concrete methods, compared with a normal class who has all three methods which are also concrete.   What is the difference between them in an application, because they are now basically serving the same purpose. Why this is permissible?  Take an abstract class, let's say:  abstract class A {     public void open() {}      public void close() {}      public void pull() {} }   And a normal class:  class A {     public void open() {}      public void close() {}      public void pull() {} }   What's the difference between them, because if we remove the abstract keyword then both are same.  Can anyone explain it?

Are there some practical programming situations for someone to declare a class abstract when all the methods in it are concrete?


I want to learn how to write math using LaTeX. I have a mac and have downloaded MacTex. I have used  and have learned the very basics of writing with MathJax and I liked how when I wrote, the displayed formula came up right underneath   I have tried producing this same equation in LaTeX and got numbered equations instead.     So my questions are:    How do I write without the (1) and (2) in LaTeX?  Can I/how do I program LaTeX to display the formulas typesetted nicely automatically (perhaps beneath the raw text, like in MathJax) instead of constantly clicking the Typeset button?  Where is a good place to learn (so far I have been using  to look how to write symbols I need).

Which book (free or otherwise) was the most useful to you when you started learning LaTeX?  I am frequently asked this question by friends who want to learn LaTeX, and I recommend the book which got me started, , but I feel that there might be better options around.  Also see .


In this code:  Console.WriteLine("Hello {0}", name);  How is this {0} called? I'm starting in C# and I've seen some codes with this. I kind of know how it works, but why should I use ("Hello {0}", name) instead of ("Hello " + name)?

In a dictionary like this:  Dictionary<string, string> openWith = new Dictionary<string, string>();  openWith.Add("txt", "notepad.exe"); openWith.Add("bmp", "paint.exe"); openWith.Add("dib", "paint.exe"); openWith.Add("rtf", "wordpad.exe");  Console.WriteLine("For key = \"rtf\", value = {0}.", openWith["rtf"]);   The output is:     For Key = "rtf" value = wordpad.exe   What does the {0} mean?


I am trying to work out the precise equivalent of this code using new instead of malloc. Pointer to pointer to float array[4]:   float (**f)[4] = (float(**)[4])malloc(2 * sizeof(float(*)[4])); for (int p = 0; p < 2; p++) {     f[p] = (float(*)[4])malloc(3 * sizeof(float[4])); }   I have tried a bunch of combinations, but cannot find the correct syntax.  float (**f)[4] = new ...

What is the difference between new/delete and malloc/free?  Related (duplicate?):


I can't seem to add a bounty to one of my questions on SO - what are the rules governing adding bounties?

It's possible to offer and award bounties of reputation on questions.   What is a bounty? How can I find questions that have a bounty attached? How do I start a bounty? When can I start a bounty? Why is the system requiring me to choose a bounty amount that's higher than the minimum? Can I use Markdown formatting in the bounty remarks? Can I edit the remark? How long is the bounty period? How do I award a bounty? Can I award a bounty to my own answer? Can I award a bounty to an old answer? If I offer a bounty on someone else's question, can I award the bounty to their answer? After awarding the bounty, can I remove it or move it to another answer at a later time? What happens if there's no answer after the bounty period? What happens if I feel my question is still unanswered? What is automatic awarding? Are bounty awards exempt from the 200 points/day reputation limit? How does Community Wiki mode affect bounties? How does user deletion or post dissociation affect bounties? Can I award a bounty to an answer from a deleted user or one where the author was dissociated? Can I offer a second bounty after the first one has expired? Can I raise my bounty? What happens if a bounty question is closed or deleted? Why can't I vote to close or migrate a bounty question? What happens if I delete my account while I have an active bounty? Do I keep an awarded bounty when I delete my answer? What happens if a question where I awarded a bounty later gets deleted or migrated? Can I cancel my bounty? Can I affect / divide / share part of my bounty to two (or more) users? How many outstanding bounties can a single user have?      See also:  in the Help Center


Suppose $n$ is even positive integer and $H$ is a subgroup of $\mathbb Z_n$. Prove that either every member of $H$ is even or exactly half of members of $H$ are even.  Same question have been asked , but I ask it again because I do not understand answers because of concepts like isomorphism and cosets etc. Need a simple answer.  Thanks

Suppose $n$ is an even positive integer and $H$ is a subgroup of $\mathbb Z/n\mathbb Z$. Prove that either every element of $H$ is even or exactly half of its elements are even. (Gallian, Contemporary Abstract Algebra, Exercise 24, Chapter 3.)


I just came up with the idea to put some kind of an advertisement (although I am not getting paid for it) in my profile.   Is it allowed?   If not, I will remove it.

Users often put links to their projects on the userinfo pages (for example,  has a link to Amazon selling C# in Depth) and that looks quite allright. However some users push this to the limit creating accounts solely for advertising purposes.  What is the policy for advertising on userinfo pages? How much is too much?


I'm sure this is a duplicate but I can't find an answer. I'm new to C# and having trouble understanding why this is happening: I have one class that inherits from another. I want the subclass to override a public field on the superclass, in this case the public field a. But it doesn't seem to work: class Foo {    public string a = "x";     public string A()    {       return a;    } }  class Bar : Foo {    public string a = "y"; }  ...  new Foo().A() // Returns "x" new Bar().A() // Returns "x" also...why?  I would expect the last line to return "y" but instead it returns "x", ignoring the fact that I've overridden the value of the a field. Why isn't it working? And what is the standard way of getting the behavior I want? I'm entering this code into the csharp REPL, if that matters.

What's difference between shadowing and overriding a method in C#?


I am trying to understand why a line in the following proof is true. Suppose $p$ is prime and $p|ab$ where $a$ and $b$ are integers. If $p$ does not divide $a$, then $a$ and $p$ are coprime, and so there exist $x,y\in\mathbb{Z}$ such that $ax+py=1$. Then we have $abx+pby=b$ and $pby=b-abx$. Hence $p|b-abx$.  Now, the next line in the proof says that this implies that $p|b$. Why is this so?

The proof is already given in the textbook but I tried other way around.   Proof by contradiction: Let's assume that $p$ doesn't divide $a$ and $p$ doesn't divide $b$, but $p$ divides $ab$. So $\gcd(p,a)=1$ and $\gcd(p,b)=1$. Given that we can construct linear combinations   $sp+ta=1$ together with $up+wb=1$. Multiplying the left and the right sides of the equations we get  $spup+spwb+taup+tawb=1$ or $p(sup+swb+tau)+ab(tw)=1 \implies \gcd(p,ab)=1$. This is a contradiction.   Is it rigorous and sound proof?


I would like to show that $\mathbb{Z}[\phi]$ is a UFD, where $\phi^2+\phi+1=0$. I started with a division with remainder to determine the irreducibles, but I could not finish that, and I do not know how to approach this problem. Could you provide me with some resources or show how I can solve this? Thanks in advance.

Is $\mathcal{O}_{\mathbb{Q}(\sqrt{5})} = \mathbb{Z}[\phi]$, where $\phi={1+\sqrt{5}\over 2}$ is the golden ratio?  I know that $5 \equiv 1 \mod 4$, so that then $\mathbb{Z}[\sqrt{5}]$ is not closed as far as integers go. But I'm a little confused cause  $\mathcal{O}_{\mathbb{Q}(\sqrt{-3})} = \mathbb{Z}\left[-\frac{1}{2} + \frac{\sqrt{-3}}{2}\right]$? So how do I know when to use $\frac{1}{2}$ rather than $-\frac{1}{2}$? Which one applies for $\mathcal{O}_{\mathbb{Q}(\sqrt{5})}$?


I'm curious if there is any math formula for this.  Let's take a close-up of a human face for instance, given the human face is about 20cm/8 inches, how do I choose the right focal length and from what distance a camera with a APS-C sensor should be so that it fits in the top and the bottom of the frame with the whole face?  I just want to know how to mathematically calculate this. It doesn't matter the effects or distortions caused by a telephoto or a wide-angle lens.

I need to purchase my first ever lens. So far I've only used lenses that were built into a camera. This specific lens is for the BlackMagic Deign Pocket Cinema Camera (a video only camera, but one that uses photography lenses). I would prefer this to be a prime lens.  I have tried to find the exact way to calculate the focal length of the lens I need but I have not been able to find a good resource to make this simple enough for my limited optics knowledge. Can you please explain a simple way to calculate the focal length of a lens given the following inputs as an example:    I would prefer a simplified mathematical explanation so that I may use it to make similar determinations in the future using a "" method.  I have . Using that method, I came up with:  Required lens focal length = 7.02mm sensor height x (77in / 36in) = 15mm   Is that correct?


$n$ is a natural number and $p$ is prime.  I have seen the question that is marked as duplicate, but it does not awnser my question.  This is what I tried: First suppose $n\equiv 1$ mod $q$. Then $1 + n+\dots n^{q-1}\equiv 0$ mod $ q$. So there's an $a$ with $ap\equiv 0$ mod $q$. From here I want to show $p=q$, but don't now how to continue.  Now suppose $n\not\equiv 1$ mod $q$. We know $p(n-1)\mid (n^q - 1)$, so there's an $a$ with $ap(n-1) = (n^q -1)$. Using Fermat's little Theorem we see $ap\equiv 1$ mod $q$. From here I want to show $p\equiv 1$ mod $q$, but again don't know how to continue.  I would appreciate any help.

let q be an odd prime and p a prime dividing $1+n+\dots+n^{q-1}$. Prove that $p = 1 \mod q$ or $p = q$.  I don't actually know how to start, i thought of using fermat's little theorem or an application of eulers formula, but it didn't really give me any insights.   Any hints?


I have a 32GB Sandisk Cruzer Flash drive when I connected it to my PC it read 14MB. What went wrong and How can I fix it?

I have a brand new 32GB flash drive that was bought from Hong Kong but manufactured in China.  When I plug it in, it's detected, and when I examine the properties of the drive the size is reported to be 31.2 GB.  Windows forces me to format it but I have not manged to actually do that.  I then I browsed the internet and a forum told me to change the letter to L. After I did that I searched many programs that can help me format it, but when I checked it back, it is 4MB now.  Any idea what's happening with my drive?


I'm running on TexMaker the following code (from ) \documentclass{article} \usepackage[utf8]{inputenc} \usepackage[english]{babel}  \usepackage{biblatex} \addbibresource{sample.bib}  \begin{document} Let's cite! The Einstein's journal paper \cite{einstein} and the Dirac's  book \cite{dirac} are physics related items.   \printbibliography  \end{document}  I'm pressing F1 to compile but no bibliography shows up. What should I do?  My Quick Build cycle is: PdfLaTex + Biblatex + PdfLaTex (x2) + Pdf Viewer I have also tried to delete the Biber cache, reboot TexMaker and compile again but nothing showed up anyways.

Running the minimal example  \documentclass{article} \usepackage{filecontents} \begin{filecontents*}{\jobname.bib} @ARTICLE{example,   author  = {Other, Anthony Norman},   title   = {Some things I did},   year    = {2014},   journal = {J.~Irrep. Res.},   volume  = {1},   number  = {1},   pages   = {1-10} } \end{filecontents*} \usepackage[backend=biber]{biblatex} \addbibresource{\jobname.bib} \begin{document} Hello\cite{example}. \printbibliography \end{document}   I get the warning There were undefined references.  I have read  and know that I need to run:   LaTeX Biber LaTeX   However, my editor is only set up to run BibTeX. How do I go about setting up my editor/IDE to be able to run Biber, and how do I run the LaTeX/Biber/LaTeX cycle?  Answers (sorted alphabetically by editor name)                    Answer guidelines   Each answer should be for one editor. If the editor is cross-platform, if possible give a single answer with notes covering the minor platform variations. Please edit the question to include new answers in the 'link list' Each answer should be 'stand alone', i.e. don't say 'It's almost the same as editor Y but ...' for the editor part Instructions for 'build tools' such as arara or latexmk are welcome but should explain how to set up the editor in question as not all editors allow simple addition of arbitrary tools


Starting to learn C++, I fell on this - If I created a class template/function template I need to know in advance possible "types" that may use it. So I need to declare something like : class template ClassName<type1,type2>;  The line above causes a specialization to be instantiated for specific function and linker attaches calls to that instance. But then question is how STL containers/algorithms etc achieve that for "any" user object? Seems like this has to do with interface of application. Excuse me if this is a duplicate question but I did not find any answer on google or StackOverflow. If it is already there, a pointer would help.

Quote from :     The only portable way of using templates at the moment is to implement them in header files by using inline functions.   Why is this?  (Clarification: header files are not the only portable solution. But they are the most convenient portable solution.)


So I recently discovered that feature requests such as  and  have already been partially implemented. Any title beginning with a phrase in [square-brackets] will trigger a popup warning:    Unfortunately, as you can see, the above screenshot comes from a per-site meta, where questions about tags are frequent and so putting tag names in titles shouldn't be discouraged.  Please disable this warning on meta sites.  I've never seen a meta question badly titled in that way; people with enough site experience to know about meta generally also have enough to know not to put tags in titles. The popup is at best useless, at worst actually wrong - after all, discussion of tags is encouraged on meta.

If you start the title of a question with a construction like "[tag]", you get a red box telling you that:     Title contains a [tag] prefix; please use the tag field to enter tags instead.     And so, I can't title this post "[tag] prohibition in titles on meta sites is inappropriate". A travesty!  This blocking dialog is certainly appropriate on all main sites, but is not appropriate on meta sites (child and Meta.SE alike), where "[tag]" may legitimately be used at the beginning of a post title to refer to the main-site tag "[tag]". Enclosing tag names in square brackets is a somewhat-established convention (I guess because that's how you search for them), which is why I tried to do that.   Yes, I know I can work around this by rephrasing my title so that the tag name is not at the beginning of the title, or by not enclosing the tag name in brackets. Still should be changed, in my opinion.


Intuitively, it is not.   Can anyone give a proof?

Show $\mathbb{Q}(\sqrt{2},\sqrt{3})$ is a simple extension field of $\mathbb{Q}$.     Since $\sqrt{2},\sqrt{3}\in \mathbb{Q}(\sqrt{2},\sqrt{3})$, and $\sqrt{2}\sqrt{3}=\sqrt{6}\in \mathbb{Q}(\sqrt{2},\sqrt{3})$, so $\mathbb{Q}(\sqrt{2},\sqrt{3})=\mathbb{Q}(\sqrt{6})$, hence $\mathbb{Q}(\sqrt{2},\sqrt{3})$ is a simple extension field of $\mathbb{Q}$.     Does my argument right? The only information I have is : A field extension $E$ of $F$ is called a simple extension if $E = F(\alpha)$ for some $\alpha \in E$.


Earth and an Earth-like planet with human inhabitant, the people of which have mental powers that enable them to control people. Their society is ranked by the number of people they can control. The top ranking leaders are known as 70's (80's?) because they can control up to 80 people. Ranking is done by challenging people (like judo). People on Earth start to disappear and it is thought that someone is kidnapping them and taking them to the other planet. Since Earth people have no mental powers, it is thought that a limitless number could be controlled as slaves. A joint investigation is agreed and an Earth detective is partnered with a "40" from the other planet. In the end a rogue "70" was found to be the person. It's not Caves of Steel since that's about robots.

Back in the 70's my local library had a novel about a human coming to a human-colonized (I think) planet where mind control was common and where he was there to solve a crime. There was a hierarchy based on how many other people you could control, starting in the single digits and eventually going by tens up to eighty or so. The main character's local associate was something like a 40 working on 50, and our hero gets in trouble with his associate at one point for interrupting a mind duel he's engaging in on the road to 50.   Those in the single digits do most of the grunt work, though fortunately for our main character those who have no mind-control powers at all are exempt - he also chats with a "disabled" native at one point who is very glad to be disabled and out of all the competition.  Standard attire is a catsuit with your number over your heart, and what I remember most about the (hardback) book is the dustjacket, which depicted a woman who filled out her catsuit exceptionally well.  I have a vague recollection that the book was originally published in the 50's, but I wouldn't swear to it.


The greatest common divisor of two positive integers $a$ and $b$ is the largest positive integer that divides both $a$ and $b$ (written $\gcd(a, b)$). For example, $\gcd(4, 6) = 2$ and $\gcd(5, 6) = 1.$  $(a)$ Prove that $\gcd(a, b) = \gcd(a, b − a).$  $(b)$ Let $r\equiv b (\mod a)$. Using part $(a)$, prove that $\gcd(a, b) = \gcd(a, r)$.  Can someone help me explain how to do this question $?$

I know that Greatest common divisor of two positive integers $a$ and $b$ is the largest positive integer that divides both $a$ and $b$, but how can I use that to prove that $\gcd(a, b) = \gcd(a, b-a)$.


Let's deal with a classification problem. I am thinking of a binary classifier but would be interested in classifying multiple categories, too. In logistic regression, we get the same parameter estimates whether we estimate the parameters using maximum likelihood or if we use the parameters that minimize cross-entropy loss. Can we say the same of a neural network, or do we use cross-entropy loss because of the relationship between likelihood and cross-entropy in logistic regression?

There is a statement that maximizing the likelihood is equivalent to minimizing the cross-entropy.  Are there any proof for this statement?


I am confused with a comparison between aliases in Strings and aliases in Arrays.   String a = "hello"; String b = "hello"; a == b; >>> true  int [] a = {1,2,3}; int [] b = {1,2,3}; a == b >>> false   I knew in Strings, when you call new String method, it would direct to a different address. Otherwise, it would take the previous address with the same String literal.  However, things do not work for arrays. Can someone explain why it gives false?

I've been using the == operator in my program to compare all my strings so far. However, I ran into a bug, changed one of them into .equals() instead, and it fixed the bug.  Is == bad? When should it and should it not be used? What's the difference?


I've asked a  on .   My question has received no direct answers (yet), but a very interesting discussion took place in the comments. I believe that reading through it pretty much helped me understand and formulate the answer. I would like to answer my own question with a summary of that discussion, listing every participant and quoting them. The discussion itself was overburdened by a couple of discrepancies in terminology, which might be interesting, yet it clearly is not related to the question itself.   Is this a decent thing to do?

I came across  and at the time there were no suggested answers. After reading Mark Hubbart's comment (at the time with four upvotes), which was the correct answer, and seeing that it had been over 30 minutes since his comment, I figured I would provide that answer in my own words, which I did. My answer is longer, and I think more rounded and more useful, but the core of the answer came from the comment. I have no idea if I'd have thought up the answer on my own--a definite maybe to that.  Now had I tried to be "honorable" or something, such as instead of answering, suggesting to the commenter that he make his comment an answer, I would only have accomplished giving away easy rep to some other user not as into gratuitous self-denial.  The commenter had merely to enter his comment into an answer box instead of a comment box! It was his choice! Whether he was too lazy or didn't think his answer worthwhile or some other reason is not my responsibility. Must I bend over backward to help him earn points that he so carelessly left lying around for another person to take? It just took a tiny bit of non-laziness on my part to get my text typed into the box that would reward me instead of the box that wouldn't.  If my perspective is incorrect and the community would rather see such answers-as-comments rewarded and supported, I will gladly accept that. In the meantime, I just want to shake off the tiny bit of guilt my overly-nice and overly-concerned-with-propriety self is feeling. :)


I keep getting:  Exception in thread "main" java.lang.NullPointerException at TTTPlayer.setBoard(TTTPlayer.java:55)     at TTTPlayer.inputMethod(TTTPlayer.java:35)      at TTTPlayer.main(TTTPlayer.java:23)   My program is a tictactoe program and I am trying to asign the value the person inputs to the corresponding array index, which then can be printed out. I know I do not have a flip flopper yet for the switching of the players. I can't figure this out though.  import java.util.*;  public class TTTPlayer {      public static String[][] board;     public static String currentPlayer;      public TTTPlayer() {         currentPlayer = "x";         board = new String[3][3];         board[0][0] = "1";         board[0][1] = "2";         board[0][2] = "3";         board[1][0] = "4";         board[1][1] = "5";         board[1][2] = "6";         board[2][0] = "7";         board[2][1] = "8";         board[2][2] = "9";     }      public static void main(String[] args) {         inputMethod();     }      public static void inputMethod()     {         TicTacToeMain.printBoard();         Scanner Input = new Scanner(System.in);         System.out.println("Enter what square you would like to place in.");         String choice = Input.nextLine();          if(choice.equals("1")||choice.equals("2")||choice.equals("3")||choice.equals("4")||choice.equals("5")||choice.equals("6")||choice.equals("7")||choice.equals("8")||choice.equals("9"))         {                setBoard(choice);          }            else         {                System.out.println("That is not a valid choice, please retry.");             inputMethod();          }         }     public static void setBoard(String choice)     {         String choice1 = choice;           for (int i = 0; i < 3; i++) {               for (int j = 0; j < 3; j++) {                 if(board[i][j].equals(choice1)){                   board[i][j].equals(currentPlayer);                   printBoard();                 }              }         }         //System.out.println(choice1);       }      public static void printBoard()     {          System.out.println(board[0][0]+" | "+board[1][0]+" | "+board[2][0]);        System.out.println("——|———|——");        System.out.println(board[0][1]+" | "+board[1][1]+" | "+board[2][1]);        System.out.println("——|———|——");        System.out.println(board[0][2]+" | "+board[1][2]+" | "+board[2][2]);      } }

What are Null Pointer Exceptions (java.lang.NullPointerException) and what causes them?  What methods/tools can be used to determine the cause so that you stop the exception from causing the program to terminate prematurely?


Anthology story sought. A warlord, the Master? tries to escape capture by suspended animation, but last incoming rocket salvo seals his cave in mountains. Stays suspended for far longer than thought, woken by somebody who has been marooned alone for his views. When latter realises the evil of the Master he kills him, condemning himself to solitude for the rest of his life.

Can anybody identify a short story about the last two men on Earth?  The first part of the story occurs in the years before humanity began colonizing other worlds.  One man was an evil mass-murdering megalomaniac who was defeated in a huge war that costs tens of millions of lives. He escaped justice and defeat at the last minute by hiding in a hibernation chamber to wait a few centuries to emerge. However, due to a malfunction, he did not emerge until hundreds of millions of years later.  The second part occurs millions of years later after humanity has spread throughout the entire galaxy.  A single government oversees the entire collection of human inhabited worlds. One man, who is extremely ethical, comes up with an alternative system of government. Because he is a threat to the current powers that be, he is tried and exiled. His exile is to be displaced into the far future. He chooses to live out his exile on an Earth that is no longer inhabited.  The third part occurs back on Earth in the far, far distant future.  While wandering about in his lonely exile, the ethical man comes across a hibernation chamber and opens it. He then discovers the man who just woke up was a mass-murdering psychopathic dictator who evaded justice and hoped to create a new reign of terror.


"What the hell?!" He said with surprise when he noticed my coming up the water.   Do we use my or possessive pronouns in such sentences? Or should it be     … he noticed me coming up the water"?

A.1 The lions reacted to my singing. A.2 The lions reacted to me singing. B.1 My singing alarmed the lions. B.2 Me singing alarmed the lions.  As far as I know, both A.1 and A.2 are grammatical: "me" and "my" are interchangeable, although there is a little difference in meaning. Can we say the same refering to B.1 and B.2? Why does B.2 seem ungrammatical? If it is, what grammatical rule, if any, impedes using "me" in B.2?


I need to find solutions to a matrix whose determinant is 0, and I have already shown that the matrix has infinitely many solutions. Can anyone explain me how to find the form of the solutions?   (solutions should come with a parameter that is free to choose, but there are some complicated constants in front of that free parameter and I don't know how to get to them).  Many thanks!

For the system  $$ \left\{ \begin{array}{rcrcrcr}  x &+ &3y &-  &z &= &-4 \\ 4x &-  &y &+ &2z &= &3 \\ 2x &-  &y &- &3z &= &1 \end{array} \right.  $$ what is the condition to determine if there is no solution or unique solution or infinite solution?   Thank you!


Show that the product of three consecutive integers is divisible by 504 if the middle one is a cube

How to prove that $(n^3 - 1)n^3(n^3 + 1)$ is divisible by $504$? Factoring $504$ yields $2^3 \cdot 3^2 \cdot 7$. Divisibility by $8$ can be easily seen, because if $n$ is even then $8 | n^3$, else $(n^3 - 1)$ and $(n^3 + 1)$ are both even and one of these is divisible by $4$ so $8|(n^3 - 1)(n^3 + 1)$. I'm stuck at proving divisibility by $9$ and $7$


I've noticed that sometimes instance methods do not compare as identical (using is rather than ==), even when they relate to the same bound instance method e.g.  >>> class A(object): ...     def f(self): ...             print "hi" ...  >>> a = A() >>> f1 = a.f >>> f2 = a.f >>> f1 is f2 False >>> f1 == f2 True   I've ended up using == to check to see if two variables refer to the same bound method, but I was wondering if anyone knew why is does not behave as I would expect?

My  has failed me.  In Python, are the following two tests for equality equivalent?  n = 5 # Test one. if n == 5:     print 'Yay!'  # Test two. if n is 5:     print 'Yay!'   Does this hold true for objects where you would be comparing instances (a list say)?  Okay, so this kind of answers my question:  L = [] L.append(1) if L == [1]:     print 'Yay!' # Holds true, but...  if L is [1]:     print 'Yay!' # Doesn't.   So == tests value where is tests to see if they are the same object?


How do I get the saved wifi passwords from my android kitkat phone. It is rooted and I have the adb tool. How do I do this? I know that I can download stuff to do it but I do not want to download any application as my device has no more storage. What other options do I have? I have looked around but I do not know what to do.

I have a rooted Samsung s3 mini, android version 4.1.2  How to show the saved wifi password of the router I am connected to?


I am running Windows 10 (build 1511) and my GPU is an ASUS AMD Radeon R7 260x. This particular model of the GPU suffers from a BIOS bug which causes the memory frequency to jump between 2D clocks (300 MHz) and 3D clocks (1600 MHz) randomly when not playing a 3D intensive game. This random flux causes the display driver to crash randomly, causing the whole system to hang up and whatever I've been working on to be lost.   The only workaround I've found for this issue is to use ASUS's own software called GPU Tweak II to alter the 2D clocks so that they are the same as the 3D clocks at all times. This method worked fine until AMD recently released their Crimson ReLive drivers. Ever since that update, the new drivers cause GPU Tweak (and any OC'ing software such as MSI Afterburner) to not accurately detect GPU information such as clock speeds, fan speed, etc. Without being able to read information accurately the given software cannot alter the GPU's clocks and the GPU returns to its erratic memory clock spiking.   I have older drivers with me but every time Windows updates to the latest GPU drivers I have to use DDU to uninstall them and reinstall the old drivers. Which, as you can imagine, is extremely tedious and not something I should have to deal with. Is there any way to disable the updating of GPU drivers automatically by Windows? If there exists some method to only disable GPU driver updates, that would be great, however, if it disables all hardware updates I'd be fine with that as well as all my other hardware are basically running smooth as butter and if need be I can manually download and install drivers as the need arises.  EDIT: I already Googled several results before coming here. I tried the registry trick (ExcludeWUDriversInQualityUpdate = 1) as well as setting Device Installation Properties to 'No' in System Properties. Neither helped, as when I went to check on Windows updates I see: "Advanced Micro Devices, Inc. driver update for AMD Radeon R7 200 Series - Waiting for Download".

Every time Windows 10 runs updates (which I see no way to control), it updates my graphics driver.  I like the old one because it is faster.  So, I have to reinstall it.  This is getting to be a pain.  Is there any way to stop Windows 10 from updating it again?


I want to use the nice z-buffer functions of OpenGL, but I really don't want my program to open a window each time it runs (because I want it run as fast as possible).  I am quite new to OpenGL, and I followed the tutorial to learn it. In the tutorial every example starts with:   initialize GLFW open a window initialize GLEW the real stuff   So I was thinking: hmm, since I only want to keep the real stuff, let's get rid of step 1-3. --I ended up with "segmentation error"  Then I was thinking: well, maybe GLEW is related to my real stuff, but GLFW, by its name, only does the window stuff. So I tried deleting step 1, and deleting step 1-2. --Both gave me a "failed to initialize GLEW"  Now I'm confused... What should I do?

Occassionally I hit places where I'd want to get an OpenGL framebuffer object, but where I'm not interested about opening a window of any kind.  Is it possible to create an opengl context without attaching it to a window of any kind?


I have the following result:    but I need this result:    The code I used is the following.  \begin{figure}[H]     \centering     \begin{tabularx}{12cm}{c}         \begin{tikzpicture}         \begin{axis}[             ybar,ymin=0,             width=12cm, height=8cm,             bar width=15pt,             x tick label style={                 rotate=-90},             major x tick style = transparent,             ymajorgrids = true,             xtick = data,             scaled y ticks = false,             symbolic x coords={4-Pa-Pr, 5-Pa-Pr, 6-Pa-Pr, 6-C-Pr, 6-M-Pr, 6-W-Pr, 7-Pa-Pr, 4-Pa-S, 5-Pa-S, 6-Pa-S, 6-C-S, 6-M-S, 6-W-S, 7-Pa-S},             ymajorgrids]             \addplot[fill=red!50] table[x=Sample,y=BD] {BulkDensity.dat};         \end{axis}         \end{tikzpicture}     \end{tabularx}     \caption{Bulk Density (g/cm\ap{3})}     \label{fig:BD} \end{figure}

With the help of  I managed to create histograms of binomial distributions. What I still need is to select some of the bars and fill them with a different color or mark them in another way in order to indicate probabilities like P(X < 4) or P(3 < X < 5).   This is what I've got so far.  \documentclass{article} \usepackage{pgfplots} \pgfplotsset{compat=1.7}  \begin{document} \begin{tikzpicture}[     declare function={binom(\k,\n,\p)=\n!/(\k!*(\n-\k)!)*\p^\k*(1-\p)^(\n-\k);} ] \begin{axis}[ymin=0, xmin=-0.5,axis lines=left,xlabel={$k$}, ylabel={$P(X=k)$}, x label style={at={(axis description cs:1,0.1)},anchor=north},     y label style={at={(axis description cs:-0.15,1)},rotate = -90, anchor=north}, ,     samples at={0,...,12},     yticklabel style={         /pgf/number format/fixed,         /pgf/number format/fixed zerofill,         /pgf/number format/precision=2     },     ybar=0pt, bar width=1 ] \addplot [fill=lightgray, fill opacity=0.5] {binom(x,12,0.4)};  \end{axis} \end{tikzpicture} \end{document}


I have 8 discs, currently. All LTSs, half 32-bit, half 64-bit, half KDE, half Gnome.  The 32-bit ones, my computer can't read. The 64-bit ones work, but the pixels are extremely messed up. Everything is scrambled for some reason. I press up and down and I can see things happening, but I don't know what. So, I need to know how to do this blindly.  Which option, in the boot menu of 12.04, will start the BootFromDVD? First one down? Second one down? I press down how many times? Then, once I press Enter or Right, what do I press? Guide the blind man through the maze.  Thanks!

I am trying to boot Ubuntu on my computer.  When I boot Ubuntu, it boots to a black screen.  How can I fix this? Table of Contents:


In the famous Magdeburg hemisphere experiment up to about 30 horses were used pulling on both sides of the hemispheres.  Could I achieve the same effect (same force on the hemispheres) if I replaced half the horses with a wall, i.e. attach the hemispheres on one side with a wall and have 15 horses pull on the other side?

So I came across this picture on facebook   My logic says it should show 200N, because you are pulling it with 100N on each side. On the other hand (as one of the facebook comments also stated, also saying is he is wrong he wasted 20k$ on physics degree), if you replace the right side with a wall you get this situation:    In this case I guess everyone agrees that the dynamometer would show 100N force. But if you isolate the dynamometer and "cut" the ropes on either picture, you would get the same thing. Because the system needs to be balanced, there would be 100N on each side.    And I study engineering too but I am confused by this. Why do we get the same distribution of forces, but dynamometer shows a different force?


I have upgraded 14.04 to 16.04 . Now I am trying to open the gedit from terminal by passing the command:    sudo gedit /some/where/file.txt   but it is throwing an error stating that:    (gedit:2090): Gtk-WARNING : Calling Inhibit failed: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown:   The name org.gnome.SessionManager was not provided by any .service files**   However, it is opening the file. When I try to save any modification then it is showing this error after saving the file:    (gedit:2090): WARNING : Set document metadata failed: Setting attribute metadata::gedit-position not supported   I am not getting why this is happening in 16.04 only; it was not on 14.04.

I've read  and am interested in this line:     You should never use normal sudo to start graphical applications as Root.   Why? What is the difference? Please provide a simple explanation, as I'm just a normal desktop user.


I have a date field [load_date] and a datetime2 field [load_time] that I want to combine into a datetime2.  I want to combine load_date with the time portion of load_time and create a datetime2.  It's in an existing table, and I want to SET the load_time to this new value.  Below is a SELECT that appears to work, so I can turn this into an UPDATE statement.  However, I wanted to know if there is a more elegant or less verbose way.  SELECT     [load_date]     , [load_time]     , DATEADD(DAY, DATEDIFF(DAY, CAST(CAST([load_time] AS TIME) AS DATETIME2), CAST([load_date] AS DATETIME2)), CAST(CAST([load_time] AS TIME) AS DATETIME2))

Given the following components  DECLARE @D DATE = '2013-10-13' DECLARE @T TIME(7) = '23:59:59.9999999'   What is the best way of combining them to produce a DATETIME2(7) result with value '2013-10-13 23:59:59.9999999'?  Some things which don't work are listed below.    SELECT @D + @T       Operand data type date is invalid for add operator.     SELECT CAST(@D AS DATETIME2(7)) + @T       Operand data type datetime2 is invalid for add operator.     SELECT DATEADD(NANOSECOND,DATEDIFF(NANOSECOND,CAST('00:00:00.0000000' AS TIME),@T),@D)      The datediff function resulted in an overflow. The number of dateparts   separating two date/time instances is too large. Try to use datediff   with a less precise datepart.   * The overflow can be avoided in Azure SQL Database and SQL Server 2016, using .    SELECT CAST(@D AS DATETIME) + @T       The data types datetime and time are incompatible in the add operator.     SELECT CAST(@D AS DATETIME) + CAST(@T AS DATETIME)      Returns a result but loses precision 2013-10-13 23:59:59.997


I know this may be a silly question. I referred some articles. But, I am very interested to know the main difference for the following code,  using System;  namespace Business {     public class User     {         private int _id;          public int ID         {             get { return _id; }             set { _id = value; }         }     } }   And  using System;  namespace Business {     public class User     {         public int ID { get; set; }     } }   I want to know some brief details (any reference)...  Thanks

Note: This was posted when I was starting out C#. With 2014 knowledge, I can truly say that auto-properties are among the best things that ever happened to the C# language.  I am used to create my properties in C# using a private and a public field:  private string title; public string Title {     get { return title;  }     set { title = value;  } }   Now, with  3.0, we got auto-properties:  public string Title { get; set; }   I know this is more a philosophical/subjective questions, but is there any reason to use these auto-properties except from saving five lines of code for each field? My personal gripe is that those properties are hiding stuff from me, and I am not a big fan of black magic.  In fact, the hidden private field does not even show up in the debugger, which is OK given the fact that the get/set functions do nothing. But when I want to actually implement some getter/setter logic, I have to use the private/public pair anyway.  I see the benefit that I save a lot of code (one vs six lines) without losing the ability to change the getter/setter logic later, but then again I can already do that by simply declaring a public field "Public string Title" without the need of the { get; set; } block, thus even saving more code.  So, what am I missing here? Why would anyone actually want to use auto-properties?


I tried posting this on Stack Overflow and was told hardware questions are not allowed (yet, most Arduino hits on Stack Exchange are at Stack Overflow). Is there a site where I can ask this question?  I need help choosing hardware, language, and IDE for an application that requires more computing power than an Arduino provides. Because of the nature of the team, it would be great if it were as easy to use as Arduino. Essential hardware features are:  interrupts, UART, SPI, and about 10 GPIO.  The code will use:  signed 32-bit numbers but it does not require floating-point support. Probably not more than 1000 lines of code if in C. The application is a high-resolution multi-channel PID controller with a simple command parser so it can be controlled by text commands via the UART. We prefer a bare-metal implementation. RTOS is not required. The board should be small and < $20 in quantities of 100. Open source is always better. Low power is not important. It should be programmable through the UART or USB.  So what are some good options to look at? There are no language restrictions. C might work but we are open to other options, for example MicroPython or eLua.

In a perfect world, the so-important advice "do not reinvent the wheel" would be extensively followed. In practice, everyday millions of wheels are reinvented simply because someone didn't know an existing solution for a specific problem. The best way to find a library, today, is googling it, but it's not always obvious which keywords to use. The lack of a tool for finding solutions is very counterproductive for the dev world as a whole. Stack Overflow is not very receptive for recommendation threads. So what about a new SE for it?


I am using apalike bibliography style and natbib for citations.  When citing "Board of Governors of the Federal Reserve" I faced the issue that the full source wasn't cited but only "Bord of Governors of". I thought I could solve this Issue by using the official abbreviation FRB, but now my Bibliography only uses the first letter of my sources "name", see image below. Is there a better way to handle long sources?  Any help would be much appreciated.

I want to list a company name in the author field of a bibliographic entry:  @book{CUDA,   author    = {NVIDIA Corporation},   title     = {NVIDIA CUDA Compute Unified Device Architecture Programming Guide},   publisher = {NVIDIA Corporation},   year      = {2007} }   But the entry keeps showing up "N. Corporation".  Is there a way to get the full author name to show up?  I'm currently using the siam BibTEX style.


I have this doubt after watching the movie Interstellar;  Lets assume I am on Jupiter. (I know it is a gas planet, full of hydrogen and helium, has extreme pressure, etc. Let's please ignore those facts for this question). As Jupiter has more gravity compared to Earth, time moves slower on Jupiter compared to Earth.  Now If i have an extraordinary telescope on Jupiter through which I am able to see the people on Earth, as the time moves much faster on Earth, will the people on Earth look like move much faster? (As we see a fast forwarding movie?)  If my understanding is completely wrong, please explain.

I've been having a discussion regarding time dilation relating to special relativity and how it should be observed from the FoR (Frame of Reference) of "the person moving" :  I assert- If we have a time is slower in the moving FoR than when I observe the stationary frame of reference (earth) then I should perceive events as occurring faster, i.e., if I observe 15 years passing and 90 years pass in the stationary frame then I should observe events on earth happening at a rate of 6:1. So if I observe a 1 min event on earth I watch that entire event occur in 10 seconds.   My thought process is similar to the idea that if I was near a massive object and looked out I would observe events further away as moving faster. My teacher seems to believe this line of reasoning is incorrect but will not (or cannot) give me the correct thought process.  Hence my question is, "is my logic correct, and if not why?"


I just bought a 6th generation iPad 2018 and was given a 10W charger along with it. I was wondering if I could use an 18W power bank to charge it. Will it damage my iPad?

I recently got a MacBook with the USB-C charger. It comes with a 29-watt power brick, and I was wondering if I should use this to charge my iPhone. I've heard that the iPad power brick (I think 10 watts) charges the phone faster. I don't expect to be able to charge the phone proportionally faster, but would the MacBook brick damage the phone? I would rather only have to carry around one charging brick around campus. Also, I have a USB to USB-C converter.


I have a UI panel for my addon, with a couple of buttons that should all invoke a custom operator class which append objects from another blend file.   My questions is how do I append specific object based on what specific button is pressed without making a new class (with an execute function attached) for each button.   I have a decent amount of scripting experience but classes and Blender's addon making are super mysterious to me. I know how to pass variable into functions, which is a technique I use when scripting, but have no idea how to do this within classes.  That's my ui_panel.py, which currently has one button but ultimately should have multiple buttons that append different objects from a blend file which store all my assets:  class UI_PT_Panel(bpy.types.Panel):     bl_idname = "UI_PT_Panel"     bl_label = "My Panel"     bl_category = "My Addon"     bl_space_type = "VIEW_3D"     bl_region_type = "UI"      def draw(self, context):         layout = self.layout          row = layout.row()         row.operator('wm.appending_basic_objects', text = "Append object")   And this is my append_operator.py, which should have a variable handling which object is appended based on which button is pressed in the UI (or something equivalent to that):  class Append_OT_Operator(bpy.types.Operator):     bl_idname = "wm.appending_basic_objects"     bl_label = "Append the basic objects"      def execute(self, context):         path = (r'C:/Users/')         blendfile = "Assets" + ".blend"          bpy.ops.wm.append(             filepath = blendfile,             directory = path + '/' + blendfile + "/Object/",             filename = 'my_object')           return {'FINISHED'}   Finally I have an init.py which only register and unregister classes (still have no idea what this mean but I know it's necessary).

For a workflow tool I made a panel in which it displays each separate library that is linked in my file. For each library I want to add some buttons that does stuff to the library in question.  So in this example I have my panel which shows for example 2 libraries and for each one it creates a "reload" button.  Now my question is.. How do I make it so the reload button only reloads the library I want to reload? I would probably have to give the button an id or something so it knows for which library it was created...  my code so far:  import bpy  libs = bpy.data.libraries  class Reloadlib(bpy.types.Operator):     """Reloads the current Library"""     bl_idname = "my.reload_lib"     bl_label = "Reload"      def execute(self, context):         libs[?????].reload()         self.report({'INFO'}, 'Reloading ' + libs[?????].name)         return {'FINISHED'}  class LibPanel(bpy.types.Panel):     """Creates a Panel in the scene context of the properties editor"""     bl_label = "Scene Libraries"     bl_idname = "SCENE_PT_layout"     bl_space_type = 'PROPERTIES'     bl_region_type = 'WINDOW'     bl_context = "scene"      def draw(self, context):         layout = self.layout         scene = context.scene         layout.label(text="Libraries:")          for i in libs:             layout.label(text= i.name.replace(".blend",""))             row = layout.row()             sub = row.row()             sub.operator("my.reload_xref", icon = "FILE_REFRESH")  def register():     bpy.utils.register_class(Reloadlib)     bpy.utils.register_class(LibPanel)  def unregister():     bpy.utils.unregister_class(Reloadlib)     bpy.utils.unregister_class(LibPanel)  if __name__ == "__main__":     register()   Where the question marks are is where I should be able to make the difference between the first [0] or second [1] library in the libs[] array.  In future I would also like to ad an 'open' and an 'unlink' button for each library so I can make changes to the other file. But this works by the same principle as the reload button.


Anyone please share info. on how I can port opus audio codec on a system running Lubuntu 14.04 Thanks.

I would like to try out the , but can't find it in the repositories.  Can anyone here help me get it installed on my computer?  I have some wav files which I would like to convert to the opus audio format.  However, I have found , but each time I click on the appropriate deb download, the package manager opens, but displays an error message saying that there are dependency issues (lib0gg0).


Regarding structures, are there any reasons not to use typedef?  like:  typedef struct{     int member1;     unsigned long member2;     char *member3; } myType;   instead of:  struct myType{     int member1;     unsigned long member2;     char *member3; };

I have seen many programs consisting of structures like the one below  typedef struct  {     int i;     char k; } elem;  elem user;   Why is it needed so often? Any specific reason or applicable area?


I am trying to learn, how to use Ajax in WordPress with proper way. This is what I learned:  Step 1: Create Ajax file and register it using wp_enqueue_script.  function wpdocs_theme_name_scripts() {     wp_enqueue_script( 'script-name', get_stylesheet_directory_uri() . '/js/ajxfile.js', array(), '1.0.0', true ); } add_action( 'wp_enqueue_scripts', 'wpdocs_theme_name_scripts' );   Step 2: Use ajax Like this in ajxfile.js:   $( document ).ready(function() {  $('#id').on('click',function (e){            alert("Its Working");     var up = 1;     var id = $( "#id" ).data( "user_id" );     $.ajax({             type: "POST",                 url: "runcode.php",                 data: {up:up, id:id},                 success:                     function(result){                 alert("result");                         }         }); });  });   STEP 3: adding HTML in page:        <a href="#" id="id" data-user_id="<?php echo $user_id = get_current_user_id(); ?>"    data-post_id="<?php echo $post_id = get_the_ID(); ?>">                Every time someone click on the link Its successfully alert "Its working" statement. Now I want to retrieve that data and want to add it in user meta. But its confusing me. And whats that nonce thing is? Can anyone guide me to right direction?

Im creating a visit/page views counter with ajax,jquery and php, I have been reading a few articles that recommend the use of nonces for data manipulation through ajax, however i am not sure if i need to integrate the use of nonces for my simple counter?  my code looks somewhat like this;  jquery  jQuery.ajax({         type: 'POST',         url: ajaxurl,         data: {action: 'countHits', status: 'true'},         });   php  //ajax functions add_action('wp_ajax_countHits', 'countHits'); add_action('wp_ajax_nopriv_countHits', 'countHits'); function countHits() {      if($_POST['status'] != "") {        $status= $_POST['status'];      if(!isset($_COOKIE['UNIQUEUSER'] && $status == 'true'){        $uniqueUser= get_option('stats');        $uniqueUser['uniqueUser']+=1;        update_option('stats', $uniqueUser);     } die();  }   So as you can see it is very simple, do I need to use nonces for each ajax request?(i have two separate request in my jquery which return variables one for false one for true) furthermore, if I wanted to implement nonces how would i go about doing that?


I have C++ code that uses a bitset to store which values of an enum were found in my data structures (it's actually a bit more complex, but that doesn't matter for the question).  This means that when I have an enum like this:  enum Color    {      RED    , GREEN    , BLUE    };   I want to define my bitset like this:  std::bitset<3>   Of course I don't want to hard-code the value 3.  In some cases I can simply add a 'terminator' to the enum, like this:  enum Color    {      RED    , GREEN    , BLUE    , _COLOR_TERMINATOR    };   And I can write this:  std::bitset<_COLOR_TERMINATOR>   But I cannot do this in all of my enums.  If I would do this on some of my enums, code-checkers (like Lint) would complain that not all enum-values are used in a switch-statement.  Is there a way to get the maximum of the values in an enum without changing something in the enum itself?  E.g. something like std::max<Color>?  Using Visual Studio 2013 and C++.  Thanks.

Is there a way to find the maximum and minimum defined values of an enum in c++?


Recently i have created an app which uses custom JavaScript in sidebar home page component using custom links, The app works perfectly and i also uploaded it to appexchange as managed released package and submitted it to review by salesforce.  Unfortunately review is negative saying Custom javascript is not allowed to run on Salesforce DOM. Below is details     1) Javascript in Salesforce DOM Vulnerability      Notes      Custom javascript is not allowed to run on Salesforce DOM.       Please check the requirement checklist for more information          Please guide how to resolve this.  **Custom Link Body:** {!REQUIRESCRIPT('/soap/ajax/29.0/connection.js')}  {!REQUIRESCRIPT('/resource/customjavascript')}

Reading through this doc:      We replaced the rich text editor in HTML Area home page components   with a new version that supports more markup but doesn’t allow HTML to   be manually entered.      In Summer ’15 we will start removing unsupported code from HTML Area   home page components. As a result, components that contain JavaScript,   CSS, iframes, or other unsupported markup might stop working properly.   To use JavaScript or other advanced HTML elements in your home page   component, we recommend that you use a Visualforce Area component   instead.   With Visualforce homepage component the best we could do is design fancy home page components, which has not been the big use of sidebar amongst developers. How do we do the fancy hack we do today using html components since visualforce is hosted in a different domain will the sidebar hacks even work after summer 15?     You can include JavaScript in your Visualforce page, but because the   component is rendered in an iframe on the home page layout, the   JavaScript can’t interact with the page that contains the component.   Finally why this move :(?


What's the relationship between the app.config stored in the root of the project and the user.config file stored in C:\Users\User_Name\AppData\Local\...?

What is the difference between the User scope and Application scope in app.config?


i have update to El Capitan, but latex would not work the error message problems after [0] pages. To see the problem i have got. /bin/sh: pdflatex: command not found I tried to understand what was the error in Path, but i did not figure it out  any help, i am not an advanced user!! thanks in advance

I'm using GNU Emacs from  After Migration to OSX 10.11 "El Capitan", Auctex can't run the *tex utilities anymore:  Running `LaTeX' on `poisson' with ``pdflatex  -file-line-error   -interaction=nonstopmode "\input" poisson.tex'' /bin/sh: pdflatex: command not found   There is no problem running for example pdflatex on the shell:  #pdflatex This is pdfTeX, Version 3.14159265-2.6-1.40.16 (TeX Live 2015) (preloaded format=pdflatex)  restricted \write18 enabled.   but it seems that auctex calls /bin/sh pdflatex instead, and that does not work anymore:  /bin/sh pdflatex /Library/TeX/texbin/pdflatex: /Library/TeX/texbin/pdflatex: cannot execute binary file   maybe due to El Capitan's changes to Gatekeeper sandboxing.  How can I configure auctex to run pdflatex again?


Say someone helped you of their own volition. You express your gratitude for it. Then, whenever you have an argument over something, anything, they see it fit to repeatedly mention the fact that they helped you this one time or two times or so. Is there a word or an idiom fit for this situation?

What do you call a person who keeps reminding others of one’s favors for them? When you fight with a person who then keeps telling you I did that I did this for you and so on. I want to tell them that it's inappropriate to remind others of the favors you did for them, especially if I appreciate those favors and try my best to return them.


I am a South African returning to live the country after having lived in the UK for the past 15 years. I returned on a UK passport (on a 90 day tourist visa) hoping to re-apply for my South African passport whilst here. I have found that I have run out of time to complete this process before my 90 day tourist visa expires. Can I simply take a couple of days vacation in a neighboring country and re-enter? What is the likelihood of getting a further 90 day visa?

How many times can an Australian leave and re-enter South Africa (90 days at a time without a visa) in a year, and do they need to be out of the country for a certain period of time before they re-enter?  I want to be in South Africa for as long as I can, however as an Australian without a visa I can only stay for 90 days at a time. What I would like to do is simply leave South Africa and go to another country in Africa for a few days, before returning with a new 90 day allowance.    Is this possible, or must I wait a certain period before re-entering South Africa/is there a limit to the amount of times I can do this in one year?


So I'm using Latex for the first time everything seems to work, except the citation and \printbibliography. The text in brackets is the cite ID [amsldoc02] not the number [1] and it is bold. I have looked for the problem for some time now and tried different things but I don't seem to find anything that works. My code looks like this right now.  \RequirePackage[l2tabu,orthodox]{nag} \documentclass[paper=a4,oneside,fontsize=11pt,headsepline,toc=bibliography,toc=listof,titlepage=true,DIV=15,BCOR=15mm]{scrbook}  \usepackage[ngerman]{babel} \usepackage{cmap} \usepackage[T1]{fontenc} \usepackage[utf8]{inputenc} \usepackage{lmodern} \usepackage[protrusion=true,expansion=true]{microtype} \usepackage[automark]{scrpage2} \usepackage{enumitem} \usepackage[babel,german=guillemets]{csquotes}  \usepackage{booktabs} \usepackage{longtable} \usepackage{array} \usepackage[colorlinks=false,pdfborder={0 0 0}]{hyperref} \usepackage{cleveref}  \usepackage[nottoc]{tocbibind} \usepackage{graphicx} \usepackage{tikz} \usepackage[percent]{overpic} \usepackage{pict2e}  \usepackage{amsmath} \usepackage{amssymb} \usepackage{siunitx} \usepackage{exscale} \usepackage{bm} \usepackage{verbatim}  \usepackage[backend=biber,style=numeric-comp,sorting=none]{biblatex}  \graphicspath{{images/}} \addbibresource{literatur.bib}  \begin{document}      \frontmatter          \include{sections/titlepage}         \include{sections/kurzfassung}         \include{sections/abstract}         \include{sections/erklaerung}         \include{sections/danksagung}         \tableofcontents         \listoffigures         \listoftables      \mainmatter          \include{sections/einleitung}         \include{sections/grundlagen}         \include{sections/konzept}         \include{sections/modell}         \include{sections/konstruktion}         \printbibliography      \appendix          \include{sections/anhang_a}  \end{document}   The .bib file looks like this  @manual{amsldoc02,     author={{American Mathematical Society}},     title={User's Guide for the amsmath Package},     year={2002},     month={2},     version={2.0},     url={ftp://ftp.ams.org/pub/tex/doc/amsmath/amsldoc.pdf}, }   Also I don't know if there is anything wrong with the whole code. Packages, order, etc.  I'd really appreciate the help!

I've browsed the forums and found a number of posts that have addressed this issue, but none of the solutions seem to work for me. I have the following script that I just copied from the bibtex home page to get familiar with it. Instead of the citation number I get a question mark. I compile using Latex+Bibtex+Latex+Latex+PDFLatex+ViewPDF just as has been previously suggested and the problem persists.   \documentclass[11pt]{article} \usepackage{cite}  \begin{document}  \title{My Article} \author{Nobody Jr.} \date{Today} \maketitle  Blablabla said Nobody ~\cite{Nobody06}.  \bibliography{mybib} \bibliographystyle{plain} \end{document}   My bibliography (Bib.bbl)  @misc{ Nobody06, author = "Nobody Jr", title = "My Article", year = "2006" }    Looking at previous posts one thing that is concerning is that my .bbl looks empty as shown below. Further, I don't have a .blg  \begin{thebibliography}{}  \end{thebibliography}


I write column vector using \bmatrix then I want to write underbrace and add text in this brace. but I don't how to do this. My code is    \documentclass [a4paper, 12pt, oneside]{Thesis}  \usepackage{amsmath,amssymb,amstext,amsfonts} \begin{document}      \begin{align*}     B&=      \begin{pmatrix}      \begin{bmatrix}      1 \\                 2 \\      3\\      \underbrace{b_{1}}      \end{bmatrix}      \end{pmatix}     \end{align*} \end{document}   The bracket is written in column vector but I want to put bracket and b_{1} outside the column vector. Please help me in doing this

I want to display the structure of a matrix as shown in the image below:    Can this be done using pmatrix and \underbrace?  My attempt at combining pmatrix and \underbrace results in a compile error.  \documentclass{standalone}  \usepackage{amsmath}  \begin{document} $ \begin{pmatrix} %1 & \underbrace{1 & \cdots & 1}_{k} \\ % compile error! 1 & 1 & \cdots & 1 \\ 1 & 1 & 1 & 1 \end{pmatrix} $ \end{document}


I am writing a program to take input from a file and display it on the console. The problem is that the last entry is being repeated twice. The code is as follows:-  int main(void) {     string filename;     int grades;     cout<<"Enter the filename:"<<endl;     getline(cin,filename);     ifstream inFile(filename.c_str(),ios::in);     if(!inFile){         cout<<"File does not exist."<<endl;         exit(1);     }     while(!inFile.eof())     {         inFile>>grades;         cout<<grades<<endl;     }     inFile.close();     return 0; }   Can you please help me in finding out the mistake? I have searched on the web and my code seems to be syntactically and logically correct.

The following C++ code uses a ifstream object to read integers from a text file (which has one number per line) until it hits EOF. Why does it read the integer on the last line twice? How to fix this?  Code:  #include <iostream> #include <fstream> using namespace std;  int main() {     ifstream iFile("input.txt");    // input.txt has integers, one per line      while (!iFile.eof())     {         int x;         iFile >> x;         cerr << x << endl;     }      return 0; }   input.txt:  10   20   30   Output:  10   20   30   30   Note: I've skipped all error checking code to keep the code snippet small. The above behaviour is seen on Windows (Visual C++), cygwin (gcc) and Linux (gcc).


I want to install Ubuntu and totally remove Windows 10.

I would like to see a full how-to guide on how to install Ubuntu.


I download a portable version of pdfxchange viewer from .  After unzip, I can run   PDFXCview.exe   directly, after adding its path to $PATH. Note that this is a portable version, so it doesn't need installation. Although pdfxchange viewer also has installation version, the installed pdfxchange viewer will not encounter error while editing a pdf file, so I choose the portable version.  To add OCR feature to it, I download a language file from . After unzip, I get OCRBaseLangPack.exe, and I try to run it, but I get an error saying "pdf viewer and editior was not installed. Installation aborted".  Does it mean that OCRBaseLangPack.exe can't find PDFXCview.exe? Is it because my pdfxchange viewer is portable, and doesn't need to install, so OCRBaseLangPack.exe can't find PDFXCview.exe?  How can I install OCRBaseLangPack.exe to PDFXCview.exe then?  Thanks!

Can .exe and .msi files (Windows software) be installed in Ubuntu?


My current OS is Windows and I want to start using Ubuntu. After I downloaded Ubuntu, I got a iso file and I have no idea what to do next.


This is the command I'm trying to use but it says there are missing brackets. How do I fix it?  /summon Wolf ~ ~1 ~ {Attributes:[{Name:generic.maxHealth,Base:99999},{Name:generic.followRange,Base:99999},{Name:generic.attackDamage,Base:10},{Name:generic.movementSpeed,Base:1}],ActiveEffects:[{Id:9,Amplifier:9999,Duration:9999,ShowParticles:0b},{Id:7,Amplifier:9999,Duration:9999,ShowParticles:0b},{Id:11,Amplifier:2,Duration:9999,ShowParticles:0b}]}

Often, when making a command block contraption, you need to set an entity's data tag. These tags can sometimes be very long, with many layers of nested curly and square brackets. For example, this is the command to summon a villager with a single custom trade:  /summon Villager ~ ~ ~ {Profession:3,Career:2,Offers:{Recipes:[{buy:{id:minecraft:diamond,Count:6b}},sell:{id:minecraft:diamond_hoe,tag:{ench:[{id:16s,lvl:10s}]}]}}   The single-line command block interface of Minecraft makes it incredibly difficult to find and fix errors, especially when it comes to mismatched brackets. In fact, for illustration purposes, I put an error in the above command.  What techniques can I use to find and fix unbalanced square or curly brackets when writing long and complicated data tags?


This is what I get when I go to the System Settings (Ubuntu 14.04):    I tried to reinstall ubuntu-desktop et similia but anything changed  But if I uninstall ubuntu-desktop, System Settings shows me a few options like this:    What should I do?  EDIT:  I have already tried  sudo apt-get install --reinstall gnome-control-center sudo apt-get install --reinstall gnome-settings-daemon-schemas sudo apt-get install --reinstall ubuntu-desktop

I did a fresh install of trusty 14.04, but a lot of icons are missing. I installed from DVD which was painfully slow and I hope to avoid repeating the process, especially since I started customizing stuff.  Here's my settings window:    I've tried:  sudo apt-get install --reinstall gnome-control-center sudo apt-get install --reinstall gnome-settings-daemon-schemas   None of which changed anything.  Any idea? I wanna edit preferences and none of them are in System Settings, neither in Unity Dash.


This post has examples from blender.SE but I think all sites use the same theme on mobile (through the browser, not the SE app).  I've recently offered a bounty on a question. Then I visited the page on mobile and I thought I had mistakenly awarded it! There was a blue +150 under an answer!  I then realized that on mobile there is no distinction between the "award bounty" button and the "bounty awarded" indicator:    ←  mobile  On desktop, at least in Blender.SE, the difference is highlighted by the color of the box:    ←  desktop  and the mouse-over tooltip also helps removing any ambiguity.  Should this difference be highlighted on mobile as well?

Whenever I see my currently active bounties from a mobile site, I feel as if they've already been awarded. This is how it looks from my chrome browser in Android:    The blue colour of the +100 box is too dark: on the Desktop site this colour is used when the bounty is already awarded. A lighter tone should be used in mobile sites too, to denote active bounties.


If I want to check if something is running, I do ps aux | grep flamethrower, expecting just to show the processes containing flamethrower in the name. This will always find at least one process, as grep flamethrower matches this criteria.  Is there some way to check for a specific process, in a cleaner way?

When I  search for some process that doesn't exist, e.g.  $ ps aux | grep fnord                           wayne    15745  0.0  0.0  13580   928 pts/6    S+   03:58   0:00 grep fnord   Obviously I don't care about grep - that makes as much sense as searching for the ps process!  How can I prevent grep from showing up in the results?


In Chamber of Secrets, Oliver Wood mentions that the Gryffindor team lost the game and the Quidditch cup all because Harry, the team Seeker, was in the hospital wing, recovering from saving the day. It seems to imply that without Harry, there was no Seeker, which would be ridiculous. I don't know much about sports, but I think they usually have players ready to step in as a replacement should someone become injured or something.   Does Gryffindor have a backup Seeker, and if not, why not?

In CoS Wood comments before Quidditch practice      we should have won the Quidditch Cup last year...But unfortunately owing to circumstances beyond our control...   p84, chapter 7   We learn Harry's reaction to this is that     Harry shifted guiltily in his seat. He had been unconscious in n the hospital wing for the final match of the previous year, meaning Gryffindor had been a player short and had suffered their worst defeat in three hundred years.   page 84, chapter 7   However when Harry was given detention for wounding Malfoy and thus missing a Quidditch game against Ravenclaw, Ginny was drafted in as a replacement seeker.  Therefore what's the difference as to why a replacement was sought for one game and not the other? And furthermore is there not a Quidditch squad for each team in order to accommodate for possible injuries and suspensions to one of the starting 7?


A friendly user placed a bounty on a question of mine:    The thing is, it's a pretty small bounty, and I want to augment it a bit. It doesn't seem I have an option of doing that; why?

I've asked a question on SO and set a bounty of 50 rep. on it.  Would it be possible to permit me to raise this bounty, if I see that it doesn't get enough attention?


I have noticed that when posting MATLAB code to StackOverflow that the formatting appears rather inhomogeneous, at least when viewed from my browser (OSX Safari and Firefox).   I've searched around for details on a possible solution, hoping to make the code look as nice as the corresponding C or C++ code; I did find .  Any new plans or news on this?  There was mention of a GitHub project that implements the MATLAB syntax highlighting.  The main culprit appears to be the MATLAB comment character, %. As a workaround I find myself just using regular text to explain what I would normally leave as a code comment, which makes the overall post look disjointed; anyone wishing to simply copy and paste such code examples would then have to insert the comment characters themselves, or copy and paste pieces at a time.  Are there any current plans or updates to have the code formatters better accommodate Matlab code?  Thanks.

MATLAB language posts don't look good under google-code-prettify.  As far as I understand from  post, MATLAB is currently highlighted by using the default language syntax.  For example, you can see  question. Since % is the standard in MATLAB to write comments, but it is not known, comments look weird.   However, it has an option to write a custom .js that defines a new language. I was thinking about writing myself a custom .js that will do the trick, but before I do that, I want to make sure that it will actually be used in Stack Overflow, and my effort is not in vain.  Is it possible to add custom google-code-prettify .js files to the server of Stack Overflow?


I need to find: $$\frac{d}{dx} x!$$  Is there a way to find this? If not, is there a proof that shows we cannot find it?  The graph of $x!$ Function

Taking the factorial function $x!$  I wonder if there is a method to find the first derivative of this function without making any use of the Gamma function (or related integral representations of the factorial). Maybe something like that  $$ \begin{align} \frac{\text{d}}{\text{d} x}\ x! & = \frac{\text{d}}{\text{d} x}\ (x\cdot (x-1)\cdot (x-2)\cdot \cdots) \\\\ & = ((x-1)\cdot (x-2)\cdots) + x\cdot ((x-3)\cdot (x-4)\cdots) + x\cdot ((x-2)\cdot (x-4)\cdots) + \cdots  \\\\ & = (x-1)! + x\cdot N(x) \end{align} $$  What I'm missing is a suitable $N(x)$ to express the remaining terms.  Does such a function exist?  I thought about this, observing term by term:  $$N(x) = \left(\prod_{k = 3}^{n} (x-k)\right) + \left((x-2)\prod_{k = 4}^n (x-k)\right) + \left((x-2)\cdot(x-3)\prod_{k = 5}^n (x-k)\right) + \cdots$$  But still it seems quite messy, isn't it?


I want to make my book with size 17cmX24cm but I don't know how to set it into my tex?

I have seen the options such as a4paper, a5paper, letterpaper, etc... to go in the square brackets after \documentclass, but what I want is 8.25 inches width by 10.75 inches height for one document and 6 inches width by 9 inches height for another one. How is this done?


I'm on a rather low-end machine (Intel Atom Cherrytrail) and the visual effects of Ubuntu 17.10 are not processed very well. It's so slow that it's often a bit confusing. Is there a way to disable transitions like the apps sliding in from the left bottom corner?

I just installed Ubuntu 17.10 today, and noticed that a lot of desktop environment has now changed from Ubuntu 17.04.  I'm just wondering if there is a way to change the the setting of those desktop effect for example, Change the speed of the app drawer to appear when you click it.