Get rid of all ##### errors at once in excel
How do you auto resize cells in Excel?
What is the difference between [@] and [*] when referencing bash array values? says:  If the index number is @ or *, all members of an array are referenced.  When I do this: LIST=(1 2 3) for i in &quot;${LIST[@]}&quot;; do   echo &quot;example.$i&quot; done  it gives the desired result: example.1 example.2 example.3  But when I use ${LIST[*]}, I get example.1 2 3  instead. Why? Edit: when using printf, @ and * actually do give the same results. I have an iMac, connected to the Internet via Ethernet, and an iPhone 4. I would like to share the iMac's Internet connection to my iPhone via the USB Cable (because my wife dreams of a wifi-less household).  I've set up Internet Sharing, specifying "sharing from: Ethernet  via: USB IPhone", but when I test, the iPhone cannot connect to the Internet. Is there something I need to activate on the iPhone?   iMac, mac os x version: Mountain Lion, 10.8.4 iPhone 4, IOS Version: 6.1 Joining elements of a list in GNU Make How do you handle multiple instances of setTimeout()? What is the most recommended/best way to stop multiple instances of a setTimeout function from being created (in javascript)?  An example (psuedo code):  function mouseClick() {    moveDiv("div_0001", mouseX, mouseY); }  function moveDiv(objID, destX, destY) {    //some code that moves the div closer to destination    ...    ...    ...     setTimeout("moveDiv(objID, destX, destY)", 1000);    ...    ...    ... }   My issue is that if the user clicks the mouse multiple times, I have multiple instances of moveDiv() getting called.  The option I have seen is to create a flag, that only allows the timeout to be called if no other instance is available...is that the best way to go?  I hope that makes it clear.... Story about a utopian city that periodically destroys itself This was a question my friend found in a book.  A block attached to a spring pulled by a constant horizontal force is kept on a smooth horizontal surface. Initially the spring is in its natural state. Then the maximum work that the applied force F can do is:  (a) $F^2/k$ (b) $2F^2/k$ (c) $4F^2/k$ (d) $F^2/2k$  My friend thought that the answer is (a) since the maximum displacement is $x=F/k$ and $W=Fx=F^2/k$. But he saw that the book's answer is different and he asked this question to me. I at first thought that the answer will be (a), but then I realised that this situation is somewhat similar to a charging capacitor. The final energy of the spring is actually $\frac12kx^2=F^2/2k$. So probably the answer is (d)? But the work done is still (a)? But the book says neither. It's (b). This is the logic in the book:  Method 1: in the book:  $$Fx=\frac12kx^2$$  $$x=2F/k$$  $$W=\frac12kx^2=2F^2/k$$  (since the book is an objective questions book it did not have detailed explanations)  What is wrong in the following methods?  Method 2: by calculating the maximum displacement  $$x=F/k$$  $$W=Fx=F^2/k.$$ Method 3: by calculating the final energy  $$x=F/k$$  $$\frac12kx^2=F^2/2k$$  PS: We both know calculus so don't hesitate to use it in the answers. Sieve of eratosthenes infinite primes I don't understand why the sieve of eratosthenes doesn't prove an infinite number of primes.  For example the number 2 eliminates 1/2 of an infinite number of numbers.  The next prime, 3, eliminates 1/3 of the remainder, not 1/3 of all the numbers and so on.  5 would eliminate 1/5 of the remaining numbers. Why doesn't that prove an infinite number of primes? Thanks Importing 3D DXF file into QGIS with z information as attribute value? I have a dxf file of 3d contours. after import it does have only  layer,x,y attribute and doesn't have Z attribute.  How can I provide Z attribute to create a TIN file? Can anybody explain the UNABLE_TO_LOCK_ROW error? Error Message:     Developer script exception from Nicomatic : quotepotential :   quotepotential: execution of AfterUpdate caused by:   System.DmlException: Update failed. First exception on row 0 with id   a0Q90000005PoxtEAC; first error: UNABLE_TO_LOCK_ROW, unable to obtain   exclusive access to this record: [] Trigger.quotepotential: line 14,   column 1      Apex script unhandled trigger exception by user/organization:   00590000001A6jh/00D90000000bovq      quotepotential: execution of AfterUpdate      caused by: System.DmlException: Update failed. First exception on row   0 with id a0Q90000005PoxtEAC; first error: UNABLE_TO_LOCK_ROW, unable   to obtain exclusive access to this record: []      Trigger.quotepotential: line 14, column 1   these mails are getting to my mail..........  trigger quotepotential on Quote_Line_Item__c (after insert,after update) {     Set&lt;Id&gt; quoteIds = new Set&lt;Id&gt;();     List&lt;Quote__c&gt; quotes = new List&lt;Quote__c&gt;();     for (Quote_Line_Item__c record: Trigger.new) {         if (record.Quote1__c != null){             quoteIds.add(record.Quote1__c);         }     }     for(AggregateResult ar:[                 SELECT                      Quote1__c,                      SUM(Max_Batch__c)sumMax                  FROM Quote_Line_Item__c                  WHERE Quote1__c=:quoteIds                  GROUP BY Quote1__c                 ]) {          quotes.add(new Quote__c(              Id=(Id) ar.get('Quote1__c'),              Potential__c = (Decimal) ar.get('sumMax')              ));     }     if (quotes.isempty() == false) {         update quotes;     } } Any thoughts on a semidecadian badge for people with five years service and an average of N points per year? Given that Stack Overflow is close to its fifth birthday as a public site, has any thought been given to a 'semidecadian' badge for people who have:   been registered with the site five years (a semi-decade, hence the name), scored more than N points per year on average (where N might be 1000).   The idea behind 'average of N points per year' is to allow slow starters to gain the badge eventually, rather than ruling them out in year 1.  The details are obviously subject to tweaking.  This might be a gold badge (the platinum version would be the decadian badge, with a larger value of N required — and no-one eligible for another 5 years or so).  These would complement the current Yearling badge (which is silver). How does Intel Turbo Boost work? Remap Caps Lock to Ctrl-b SOAP or REST for Web Services? Looking for old book, SF, artificial world, different zones for different species that visitors "inhabit" A fly in an accelerating car A fly is flying around in a car, the fly never touches any surface in the car only fly’s around in the air inside the car. The car accelerates. does the fly slam in to the rear window. or does the fly continue to fly uninterrupted? Making a WinForms TextBox behave like your browser's address bar When a C# WinForms textbox receives focus, I want it to behave like your browser's address bar.  To see what I mean, click in your web browser's address bar. You'll notice the following behavior:    Clicking in the textbox should select all the text if the textbox wasn't previously focused. Mouse down and drag in the textbox should select only the text I've highlighted with the mouse. If the textbox is already focused, clicking does not select all text. Focusing the textbox programmatically or via keyboard tabbing should select all text.   I want to do exactly this in WinForms.  FASTEST GUN ALERT: please read the following before answering! Thanks guys. :-)     Calling .SelectAll() during   the .Enter or .GotFocus events won't   work because if the user clicked the   textbox, the caret will be placed   where he clicked, thus deselecting all   text.      Calling .SelectAll() during the .Click event won't work because the user won't be able to select any text with the mouse; the .SelectAll() call will keep overwriting the user's text selection.      Calling BeginInvoke((Action)textbox.SelectAll) on focus/enter event enter doesn't work because it breaks rule #2 above, it will keep overriding the user's selection on focus. cardinality of the Borel $\sigma$-algebra of a second countable space Second countability by itself doesn't restrict the cardinality of a topological space, since every set with the trivial topology is a second countable space, but it seems natural to ask whether second countability restricts the cardinality of the Borel $\sigma$-algebra of the space.  Can the cardinality of the Borel $\sigma$-algebra of a second countable space be arbitrarily big? If this is the case is there a simple construction for a second countable space with an arbitrarily big Borel $\sigma$-algebra? Using Perl to change the url homepage for Internet Explorer Can someone help me out and explain or point me in the right direction on how to check video drivers and see if my video card running okay?  I had 10.04 installed on my Thinkpad r61 with Compiz Manager and life was great, until the machine took water damage. I bought an ASUS (X54H) since and am trying out 12.04, but the desktop just doesn't look right.  I always struggled with video driver installation. There are no proprietary drivers available in the hardware manager.  When I run lspci | grep VGA:  00:02.0 VGA compatible controller: Intel Corporation 2nd Generation Core Processor Family Integrated Graphics Controller (rev 09)   I will greatly appreciate your help. I want to use Linux more, but like I said video drivers appear to be my biggest concern. I have also tried 12.04 on my desktop PC, but again failed to configure video card, so switched back to Windows 7. Okay, so I understand what calculus, linear algebra, combinatorics and even topology try to answer (update: this is not the case in hindsight), but why invent category theory? In Wikipedia it says it is to formalize. As far as I can tell, it sort of generalizes a bunch of fields in mathematics, like in topology, graphs and groups we have isomorphisms and automorphisms and homomorphisms, it seems to me like it just finds a bunch of results that are true to these functions in a bunch of disciplines. But why would generalizing that be of use? I mean, wouldn't it be easier to prove them specifically in each of the important disciplines?