For filtered question lists, if seems that new questions have background colour applied until I have actually seen them in the list.  On successive viewing, it is no longer present.  However for Arduino lists of all questions, I can find no rhyme or reason to the use of such.  When there is background colour, I can see the question in the list or even open it, but there is no change following this.  What am I missing here? Surely it is intended to impart some piece of information.  I had read many FAQs and questions, but can find no reference to such behaviour.

What are watched tags and ignored tags? How do they work? What are tag subscriptions? What are interesting tags? On Stack Overflow, the content of the main page question list appears to be influenced by watched and ignored tags. How does that work?   For more information, see "" in the .


I know that there is a similar questions, but I think mine is a bit different. I wonder if with the expansion of the universe the speed of light changes. It seems that the speed of light is very connected to the space-time continuum, e.g. it follows all it's deformations etc. So if the space-time continuum expands, does the speed of light change?

I was told that the Galilean relative velocity rule does not apply to the speed of light. No matter how fast two objects are moving, the speed of light will remain same for both of them.   How and why is this possible?   Also, why can't anything travel faster than light?


Prove that $2^{n}-1\nmid3^{n}-1$ for all odd integers $n\geq3$.   After factoring the numbers for some small $n$'s, I guess $\gcd(2^n-1,3^n-1)=1$ for all odd integers $n\geq3$, but I am unable to prove this. I tried infinite descent but to no avail. It seems to have something to do with Mersenne primes. Any hints will be appreciated.

Let $n > 1$ be an integer. Then $2^n - 1\nmid 3^n - 1$. I don't know how to prove it. Can anybody help me, please?  In general, for a fixed positive integer $a > 1$, has $a^n - 1|(a +1)^n - 1$ any integer solutions?


shows that a bullet shot from a flying plane receives a large amount of energy from the plane, even much more than the energy from the propellant of the bullet.  But I wonder how can the plane transfer additional energy to the bullet? For example, the propellant gas expands and creates the pressure that pushes the bullet forward, this energy is limited by the propellant itself. While the plane only recoils backward, how can the plane transfer force, or energy to the bullet, in what method since it even does not touching the bullet? If the barrel is a part of the plane, the plane even pulls the bullet backward by friction.

For the sake of simplicity, let's imagine that the entire universe is empty except for a single lump of (classical) matter with mass $m$. In its center of momentum frame, it is clear that the total energy is simply $E_\text{CoM}=mc^2$. However, in a frame moving relative to it with speed $v$, we have $E_\text{moving}=\sqrt{m^2c^4+p^2c^2}> mc^2$ for all nonzero $v$.  Are we to infer that the energy content of a system can be different relative to the observer? Does this not violate the first law of thermodynamics?


I currently own a system with Windows 7 and Ubuntu dual boot. I want to remove the entire dual boot system and install a single Ubuntu OS.  Can I directly install Ubuntu via the flash drive without bothering about the dual boot partitions (I don't want the previous OS Windows 7 and Ubuntu partions)?

My laptop is filled with viruses and Windows XP is just becoming impossible to work with.   I've been interested in Ubuntu for a while, so, would I be able to use something like Debian to clear my HDD and OS and then install Ubuntu and start fresh?


So I have a dataframe that has the date of birth written as a string '2012-07-06T21:00:00.000Z' (example). I want to calculate the users' age from that. Note that this is a string and I think I need it to be datetime to be able to calculate it. Thank you much my code (Python): def calculate_age(born):     born = datetime.strptime(born, "%Y-%m-%d'T'%H:%M:%S.%f%Z").date()     today = date.today()     return today.year - born.year - ((today.month, today.day) < (born.month, born.day))  df['age'] = df['birth_date'].apply(calculate_age)

I need to parse  strings like "2008-09-03T20:56:35.450686Z" into Python's datetime type.  I have found  in the Python standard library, but it is not very convenient.  What is the best way to do this?


I have laptop batteries that are a few years old and lost their charges, but which I've still kept "just in case"*. However, I've heard that letting them lose all of their charges can be dangerous. Does this mean they could burst into flames one day? How much longer can I keep them around?  *Note: Yes, I do realize they probably won't hold charge anymore, but that's not my quesiton. I'm only asking about their safety, not usefulness.

I've been trying to design a charging system for a small robot powered by a 2S 20C  (LiPo) battery. Were I to trust everything I read online, I would believe that the LiPo will kill me in my sleep and steal my life savings. The common advice I read, if you are brave enough to use LiPo batteries, is "never leave unattended", "never charge on top of a flammable or conductive surface", and "never charge at a rate faster than 1 ".  I understand why this is prudent, but what is the actual risk with LiPo batteries?  Nearly every cell phone, both Android and iPhone alike, contains a LiPo battery, which most people, including myself, charge while unattended—often-times while left on a flammable or conductive surface. Yet you never hear about someone bursting into flames because their cell phone exploded. Yes, I know there are freak accidents, but how dangerous are modern LiPo batteries? Why do so many online commenters treat stand-alone LiPo batteries like bombs waiting to go off, but don't even think twice about the LiPo sitting in their pocket?


In the formula for Newton's law of gravitation i.e.  $$F = G(m_1)(m_2)/r^2 $$ here $r$ is the distance between  COM of the two objects , so we consider that the object is a single point located at it's COM and at this point gravitational force of attraction acts . Then why is sometimes COM and COG different for an object ? Please give some practical example .

My book says:     For most of the small objects, both are same. But for mammoth ones, they are really different ones. And in a gravity-less environment, COG is absent; COM still exists.   Ok, what's the big deal when things are small and big? How these two :  & ?


I'm receiving the following error:     Parse error: syntax error, unexpected '}', expecting end of file in /blah/blah/Edit.php on LINE_WITH_COMMENT   for this code inside my Edit.php view file.  <? $categories = $this->config->loader->getCategories();     foreach($categories as $category) { ?>    <?  $selected = $this->obj->category==$category ? 'selected' : ''; ?>         <option value="<?=$category?>" <?=$selected?>><?=$category?></option>     <?php } ?>  //ERROR IS HERE   But if I change <?php to the short open tag <?, the error goes away, and my script works as expected.  It works on my server with hostgator with <?php but on my local machine it's only working with <? and giving the fatal error if I have <?php.  From phpinfo() on the local machine: PHP Version 7.2.17-0ubuntu0.19.04.1  I've changed <?php to <? for now, but how can I fix this? I prefer not to use short open tags.

Here's the information :     There are four different pairs of   opening and closing tags which can be   used in PHP. Two of those, <?php ?>   and <script language="php"> </script>,   are always available. The other two   are short tags and ASP style tags, and   can be turned on and off from the   php.ini configuration file. As such,   while some people find short tags and   ASP style tags convenient, they are   less portable, and generally not   recommended.   In my experience most servers do have short tags enabled. Typing  <?=   is far more convenient than typing  <?php echo    The programmers convenience is an important factor, so why are they not recommended?


I want to import a C file with Python and run it. Imagine my C code is :  #include <stdio.h>  void sum(int num1, int num2){      return num1 + num2;  int main(){      sum(1,2) }   How do I import the C code with Python :  import helloworld result = helloworld.sum(1,2) print(result)   This doesn't work how do I make it work.     In Google I found C++ but I DO NOT want C++ I need to do it in C.

What would be the quickest way to construct a Python binding to a C or C++ library?  (I am using Windows if this matters.)


I've got a combo box with options, what I want is a function where I send one of the options, and the combo box set that option to the selected one, showing it.  I try  $("#cmbStrategies option:selected").html('Condor');   It works set Condor as the selected option, but adding it has a new option, resulting in two option Condor.  I want just select the option but not adding a new one.

I have a select control, and in a javascript variable I have a text string.  Using jQuery I want to set the selected element of the select control to be the item with the text description I have (as opposed to the value, which I don't have).  I know setting it by value is pretty trivial. e.g.  $("#my-select").val(myVal);   But I'm a bit stumped on doing it via the text description. I guess there must be a way of getting the value out from the text description, but my brain is too Friday afternoon-ed to be able to work it out.


How did Tom Riddle find out about what Horcruxes were and what they did before he asked Horace Slughorn?  Hermione wasn't about to find a single thing about them in the library when Harry brought it up and she had never heard of them prior. Where else would Tom have heard of them?

The book I'm talking about is 'Secrets of the Darkest Arts' (which is the only book covering the subject of horcruxes to my knowledge). Riddle presumably read this book prior to him asking Slughorn about them as he already knew what they were (he just wanted information on how to make multiple horcruxes). Anyway, why did they keep the book in the library (although in the restricted section) if it was a banned subject (Slughorn told Riddle the subject was banned when asked about them). Basically any student could have found the book and learned about them.


I'm new to Python so I am still getting used to looping in this language.  So, for example, I have the following code (the element type in the list is array)  my_list = [array0, array1, array2, array3] temp = my_list[-1] for k in range(len(my_list) - 1, 0):     temp = temp + my_list[k - 1] return temp   I want to traverse the list from the end of the list and stop at the second element (k=1), but it looks like the for loop will never be entered and it will just return the initial temp outside the loop. I don't know why. Can someone help? Thanks.

So I can start from len(collection) and end in collection[0].  I also want to be able to access the loop index.


How to hilighted object on mouse hover or mouse click events in Geoserver css style? Like a css :hover selector. Is it possible? Maybe it is doing after WMS/WFS?

I am using the following code and wanted to know how I can change it from click event to hover or mousemove event. I know there is a eventListner but I am unable to locate the click event where I must change it to mousemove event.  info = new OpenLayers.Control.WMSGetFeatureInfo({             url: 'http://localhost:8080/geoserver/iPlant/wms',              title: 'Identify features by clicking',             queryVisible: true,             eventListeners: {                 getfeatureinfo: function(event) {                     map.addPopup(new OpenLayers.Popup.FramedCloud(                         "chicken",                          map.getLonLatFromPixel(event.xy),                         null,                         event.text,                         null,                         true                     ));                 }             }         });         map.addControl(info);         info.activate();   Update 2.0  I made the changes and also added the PopUp, but only the click function is being recognized.  info = {             click: new OpenLayers.Control.WMSGetFeatureInfo({             url : 'http://niles.iplantcollaborative.org:8080/geoserver/wms',             title : 'Identify features by clicking',             queryVisible : true,             eventListeners : {             getfeatureinfo : function(event) {             deletePopUp();             popup = new OpenLayers.Popup.FramedCloud("popInfo", map.getLonLatFromPixel(event.xy), null, event.text, null, true);             map.addPopup(popup);}}             }),             hover: new OpenLayers.Control.WMSGetFeatureInfo({             url : 'http://niles.iplantcollaborative.org:8080/geoserver/wms',             title : 'Identify features by clicking',             queryVisible : true,                     hover : true,             eventListeners : {             getfeatureinfo : function(event) {             deletePopUp();             popup = new OpenLayers.Popup.FramedCloud("popInfo", map.getLonLatFromPixel(event.xy), null, event.text, null, true);             map.addPopup(popup);             }}             })             };             map.addControl(info.hover);             info.hover.activate();


Prove that each of the group R :  $$|x+y| \leq\ |x| +  |y|$$  Of course I'm not a lazy person I tried solving before since the teacher gave this exercise to us in the  exam. I wanted to know the right answer because we still haven't corrected the test.   Thanks and Sorry for any faults. This is my first question in this website. How would I know if it's duplicate?

I understand intuitively that this is true, but I'm embarrassed to say I'm having a hard time constructing a rigorous proof that $|a+b| \leq |a|+|b|$. Any help would be appreciated :)


I just need someone to check my proof and provide me feedback:  Since $R[x]$ is a PID, then the ideal $I = (x-1)$ generated by the polynomial $x-1$ is maximal because it is of degree 1 added to a constant.  So $R[x]/I\simeq R$ is a field, so $R$ is a field.    Is this proof enough/correct?  Thanks.

I've just read a proof of the statement:  Let $R$ be a commutative ring. If $R[X]$ is a principal ideal domain, then $R$ is a field.  In one part of the proof there is a step which I don't understand. I'll copy the proof: Let $u\in R$ be non-zero. Then using the principal ideal property, for some $f\in R[X]$ we have $\langle u,X\rangle = \langle f \rangle \subseteq R[X]$. Therefore, for some $p,q∈R[X], u=fp$ and $X=fq$. By properties of degree we conclude that $f=a$ and $q=b+cX$ for some $a,b,c\in R$. Substituting into the equation $X=fq$ we obtain $X=ab+acX$ which implies that $ac=1$, i.e. $a\in R^\times$, the group of units of $R$. Therefore, $\langle f\rangle =\langle 1\rangle=R[X]$. Therefore, there exist $r,s\in R[X]$ such that $ru+sX=1$ and if $d$ is the constant term of $r$, then we have $ud=1$. Therefore $u\in R^\times$. Our choice of $u$ was arbitrary, so this shows that $R^{\times}⊇R \setminus \{0\}$, which says precisely that $R$ is a field. I don't understand this: "$X=ab+acX$ which implies that $ac=1$, i.e. $a\in R^\times$, the group of units of $R$. Therefore, $\langle f\rangle = \langle 1\rangle =R[X]$." Why does the fact that $a=f$ is a unit implies that $\langle f\rangle = \langle 1\rangle$? I would appreciate if someone could explain this to me. Thanks in advance.


Is such any such simple Object Mode feature/operation built into Blender? If yes what is the mechanism? It is certainly built in to rotate all the objects by the exact same rotation. The result might be for example each object has a random rotation about its own origin on the Y axis.  The rotation would be present in the object rotation entries. Trusted Addons are acceptable if they of age 3 months or greater. I checked the standard Addons.  I did not recognize anything.  Rotate has a proportional edit property though I did not see an explanation in the Blender documentation. Please exclude 🚫Particles and 🚫Pythons Scripts and 🚫Modifiers/Constraints/Keyframes and 🚫BAN.  I can write Script or use Particles if necessary.

I want to create an abstract rendering of lots of cubes floating in the sky. It would be good if they could also be clustered together. I'm thinking of something sort of like this:    Does Blender have any tools for placing clusters of objects, and randomly scaling them? What's the best process to do this?


$X_n$ are r.v.s, is it true that $E[\sum_{n=1}^{\infty} X_n] = \sum_{n=1}^{\infty} E[X_n] $?  My feeling is that this is not necessarily true. But cannot come up with an example.  Can someone provide a counterexample or give a proof for this statement?

Let's say I have $\int_{0}^{\infty}\sum_{n = 0}^{\infty} f_{n}(x)\, dx$ with $f_{n}(x)$ being continuous functions. When can we interchange the integral and summation? Is $f_{n}(x) \geq 0$ for all $x$ and for all $n$ sufficient? How about when $\sum f_{n}(x)$ converges absolutely? If so why?


I have notification menu icon. I need that to be animated when onCreateOptionsMenu() called.  While implementing, i have been facing issue like below -   Attempt to invoke virtual method 'void  android.view.View.setAnimation(android.view.animation.Animation)' on a  null object reference.   Java code :  private Animation animation; @Override public boolean onCreateOptionsMenu(Menu menu) {     getMenuInflater().inflate(R.menu.home_screen,menu);      animation =   AnimationUtils.loadAnimation(getApplicationContext(),R.anim.notify);  menu.findItem(R.id.notifications).getActionView().setAnimation(animation);      return super.onCreateOptionsMenu(menu); }   home_screen.xml :   <?xml version="1.0" encoding="utf-8"?>  <menu xmlns:android="http://schemas.android.com/apk/res/android"  xmlns:app="http://schemas.android.com/apk/res-auto">  <item     android:id="@+id/notifications"     android:title="@string/action_settings"     app:showAsAction="ifRoom"     android:icon="@drawable/notifications"/>   </menu>   notify.xml :   <?xml version="1.0" encoding="utf-8"?>  <rotate xmlns:android="http://schemas.android.com/apk/res/android" android:fromDegrees="0" android:toDegrees="180" android:pivotX="50%" android:pivotY="50%" android:duration="500" android:interpolator="@android:anim/accelerate_interpolator" />   Kindly let me know the solution to resolve the issue. Thanks in advance.

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?


I have three files: main:  #include <iostream> #include "Punkt.h"  int main() {    const Punkt s1(0, 1);   const Punkt s2(-5, 2);   std::cout << "s1 " << s1.wsp<0>() <<  " " << s1.wsp<1>() << std::endl; }   header:  #include <iostream> #pragma once class Punkt{ public:     Punkt(int x, int y){         m_x = x;         m_y = y;     }      template <typename T> int wsp() const; private:     int m_x;     int m_y;  };   cpp:  #include "Punkt.h" #include <iostream> using namespace std; template <typename T>      int Punkt::wsp() const {     int obiekt(T);     try{         if (obiekt==1){             return m_y;         }         if (obiekt==0){             return m_x;         }         throw;     }     catch(...){         std::cout << "Incorrect number" << std::endl;     } }   and the problem:  Main.cpp:46:35: error: no matching function for call to ‘Punkt::wsp() const’    std::cout << "s1 " << s1.wsp<0>() <<  " " << s1.wsp<1>() << std::endl;  In file included from Main.cpp:39:0: Punkt.h:11:28: note: candidate: template<class T> int Punkt::wsp() const   template <typename T> int wsp() const;  Punkt.h:11:28: note:   template argument deduction/substitution failed:   I am starting with templates and I don't understand what is going on. When I change wsp to: 'template '(and the fuction ofc) it works fine. Do someone have any idea?

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.)


Im trying to get jTextField value in another class but always get error null exception. Here is my code :   Class Main :   public class FormTambahDoc extends javax.swing.JFrame {     Utility utility;      public FormTambahDoc() {         initComponents();         utility = new Utility();         setButton();     }      public  String gettextIdentitasPengguna() {         return textIdentitasPengguna.getText();     }       private void setButton() {         btnSimpan.addActionListener(new ActionListener() {@Override         public void actionPerformed(ActionEvent e) { utility.cek();} });     }    }   Class another:   public class Utility {  FormTambahDoc formTambahDoc; //FileJpaController controller;   public  void cek() {     String inputText = formTambahDoc.gettextIdentitasPengguna();    System.out.println(inputText);    //return `Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException`   }  }   What's wrong in this code ?


First I want to define the Legendre symbol $(\frac{a}{p})$.  $(\frac{a}{p}) = 1$ when a is a square mod p, and $(\frac{a}{p}) = -1$ otherwise.   I want to figure out when $(\frac{2}{p}) = 1, -1$. According to the answers, $(\frac{2}{p}) = 1$ for $p = 1, -1 (mod 8)$ and $(\frac{2}{p}) = -1$ for $p = 3, -3 (mod 8)$. What I can't figure out is how to get to the answer.   What I do know is that for any odd prime $p$, $p = 1, 3 (mod 4)$ and intuitively it seems that this is related to $mod 8$ somehow,  but I'm not sure how to make the connection.  Any help would be appreciated! (And apologies in advance for my horrible formatting here.)

$$\left(\frac{2}{p}\right) = (-1)^{(p^2-1)/8}$$ how did they get the exponent. May be from Gauss lemma, but how.  Suppose we have a = 2 and p = 11. Then n = 3 (6,8,10), but not  $$15 = (11^2-1)/8$$  n is a way to compute Legendre symbols from Gauss lemma: $$\left(\frac{a}{p}\right) = (-1)^n$$


Let $f$ be a real valued continuous function on the interval $[0,1]$ such that $$\int_0^1  x^n f(x) dx=0$$  for $n=0, 1, 2 ...$. Show that $f$ is identically zero.

As the title says, I'm wondering if there is a continuous function such that $f$ is nonzero on $[0, 1]$, and for which $\int_0^1 f(x)x^n dx = 0$ for all $n \geq 1$. I am trying to solve a problem proving that if (on $C([0, 1])$) $\int_0^1 f(x)x^n dx = 0$ for all $n \geq 0$, then $f$ must be identically zero. I presume then we do require the $n=0$ case to hold too, otherwise it wouldn't be part of the statement. Is there ay function which is not identically zero which satisfies $\int_0^1 f(x)x^n dx = 0$ for all $n \geq 1$?  The statement I am attempting to prove is homework, but this is just idle curiosity (though I will tag it as homework anyway since it is related). Thank you!


Screenshot tells more than 1000 words:    (Oh and I think it's not an exact duplicate of  because it's only about overlapping parts of the post's content including flag bar if I read it correctly, not about overlapping UI which should be above it because it's a floating dialog box - although it probably has the same cause.)

When a post is deleted and the notification comes through, it scrolls over the inline flag bar:    The entire post also seems to capture clicks instead of letting them get to the flag bar. Looks like someone got a z-index wrong...


Good afternoon, everyone!  Which one is correct:   I live in this street I live on this street   I would like to know which one is correct or whether both of them are possible in standard English. If they are both possible, which one is more common in British English?  I know that we usually say: "I live on Fennel Street" (on+street name) and "I live at 10 Fennel Street" (at+house number), but I would like to know which preposition should be used preceding the determiner "this" and/or when we are pointing at the street where we live.

He lives on Main Street.   This sentence is from "Merriam-Webster " Dictionary.  But I found both usage " in the street" and "on the street." on ngram.  What is the difference between them, "live on street" or "live in street".


I am setting up iptables on a new instance of Ubuntu 14.04 server. So far I have:   put iptables rules into a file /etc/iptables.firewall.rules created a script /etc/network/if-pre-up.d/iptablesload.sh and put the following code in it   #!/bin/sh iptables-restore < /etc/iptables.firewall.rules exit 0   The firewall rules work, e.g. if I manualy  run the command from a prompt  $ iptables-restore < /etc/iptables.firewall.rules   the iptables rules get applied. But when I reboot the server the firewall is not up - how can I fix this?

I usually run my iptables rules whenever I login. From the terminal I type ;  sudo sh firewall.sh   Setting up my sister's computer, I want to give her some basic firewall protection. She wont be logging in as admin, just a standard account. How can I make a firewall script run everytime she logs in without her having to type in any password?  The script I wrote for my sister's computer contains ;   #!/bin/sh  modprobe ip_conntrack iptables -F iptables -X iptables -P INPUT DROP iptables -P OUTPUT DROP iptables -P FORWARD DROP  iptables -I OUTPUT -p tcp --dport 80 --sport 32768:61000 -j ACCEPT iptables -I OUTPUT -p udp --dport 53 --sport 32768:61000 -j ACCEPT iptables -I OUTPUT -p tcp --dport 443 --sport 32768:61000 -j ACCEPT iptables -A OUTPUT -o lo -j ACCEPT iptables -I OUTPUT -p icmp -j DROP  iptables -I INPUT -p icmp -j DROP iptables -I INPUT -p udp -j DROP iptables -I INPUT -p tcp -m tcp --syn -j DROP iptables -I INPUT -i lo -j ACCEPT iptables -I INPUT -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT   I've placed it in her home folder as firewall.sh and set it to be executable (right click on the file, and checking the "allow executing file as program" option in the permissions tab).  Running this script from the terminal as root works fine.    After typing ;  sudo sh firewall.sh   I typed into the terminal  sudo iptables -L -v   and I get  Chain INPUT (policy DROP 0 packets, 0 bytes)  pkts bytes target     prot opt in     out     source               destination              0     0 ACCEPT     all  --  any    any     anywhere             anywhere             ctstate RELATED,ESTABLISHED     0     0 ACCEPT     all  --  lo     any     anywhere             anywhere                 0     0 DROP       tcp  --  any    any     anywhere             anywhere             tcpflags: FIN,SYN,RST,ACK/SYN     0     0 DROP       udp  --  any    any     anywhere             anywhere                 0     0 DROP       icmp --  any    any     anywhere             anywhere              Chain FORWARD (policy DROP 0 packets, 0 bytes)  pkts bytes target     prot opt in     out     source               destination           Chain OUTPUT (policy DROP 0 packets, 0 bytes)  pkts bytes target     prot opt in     out     source               destination              0     0 DROP       icmp --  any    any     anywhere             anywhere                 0     0 ACCEPT     tcp  --  any    any     anywhere             anywhere             tcp spts:32768:61000 dpt:https     0     0 ACCEPT     udp  --  any    any     anywhere             anywhere             udp spts:32768:61000 dpt:domain     0     0 ACCEPT     tcp  --  any    any     anywhere             anywhere             tcp spts:32768:61000 dpt:http     0     0 ACCEPT     all  --  any    lo      anywhere             anywhere   How can I have this this script run automatically at login, or possibly save these rules permanently for my sisters computer? Could you please provide some detailed code, as my first attempts at rc.local method and iptables-save have not been very successful. On every reboot, all INPUT, OUTPUT and FORWARD chains are reset to ACCEPT, with no policies listed when I type sudo iptables -L -v


using the toString method to add characters into my string I form the word "LAUGHTER". However, the program does not recognize the word = "LAUGHTER" and therefore it did not enter my if loop. Any idea why is it like that?  word += Character.toString(cList.get(i));  if(word == "LAUGHTER" ) {     System.out.println(word); }

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?


Other answers helped but have a problem with the following  Start Time 23:56 End Time 0:32 difference is 36 minutes.  Start Time 21:53 End Time 22:05 difference is 12 minutes.   What formula can I use to get the amount of minutes using a 24 clock time frame.  As I just want to enter my times and have Excel do the rest.  Hope this makes sense and someone can help with an answer.

I have time values in two cells in an Excel sheet and I need the difference of the times in minutes.  The cells in the Excel are like below:     A        B        C 1  6:38     8:23     1:45:00   A is the start time B is the end time C is the time difference (B1-A1) which is displayed in hh:mm:ss format  A and B cols are formatted as custom hh:mm and cell C is formatted as custom hh:mm:ss.  But I need to get in the value in cell C1 as 105 instead of 1:45:00.  Could you please help in displaying time only in minutes and giving the right format?


Can you please explain me what is electric flux. I know it is $\int\mathbf{E}\cdot\mathrm{d}\mathbf{S}$, but in many place its given flux means to flow. But how does electric field "flow"? Also if we assume its the electric field lines (can you also specify what exactly are these) are "flowing" how does $\int\mathbf{E}\cdot\mathrm{d}\mathbf{S}$ give the total electric field lines passing through that area? (can you please elaborate when you explain?)  Pls. I know it shouldn't come here but there is no page for electric flux.

Flux, as I understand it, is the amount of substance passing through a particular surface over some time. So, from a simple perspective, considering photons that go through some virtual surface $A$ (or $S$, doesn't matter). They have a fixed speed in vacuum, $v=299,792,458$ $\text m/\text s$. To simplify even further, they're all hitting the surface head-on. So, if we wanted to figure out how many photons go through the surface, we conclude that at a constant velocity they will only pass through the surface if they are in the volume bounded by sweeping the surface area along the velocity vector (perpendicular to the surface, the opposite of its normal) a distance $d$ in the alloted time $t$: $d = vt$  So the flux volume is well-defined as $V(t) = Avt$. We could just look for a period of unit time and "drop" the dependency on time. But even then, it's useless if we cannot sample photon volume density $\rho_p$ to determine how many photons occupy a unit volume in order to determine the actual flux. That makes sense:  $$\Phi = \rho_pV(t)$$  And now comes along the electric flux and thwarts my understanding of the whole notion completely. An electric field is generated when a charge is dropped somewhere in space. Any other charge, especially idealized point charges, placed in its vicinity would experience a force exerted on them by the source charge, its magnitude modulated by the amount of charge. So, the electric field maps points in space with force vectors (ie. a vector field) whose direction and magnitude is parametrized by the interaction between the source charge and the point charge.  And this electric flux is defined as $\Phi = E \cdot S$ (I'll use $\Phi = E \cdot A$) and I just cannot interpret the semantics of this dot product, the product's dimensionality is not what I've come to expect from the notion of flux ($\text{Vm}^{-1}$ or any other). How does this in any way show how much electric field flow goes through a surface? Furthermore, what is this vague thing called electric field flow? It seems like it is completely disconnected.  I've tried expressing it in different ways from the derivation of the expression of an electric field, which makes sense (non-vector form, dropped unit vector):  $$E = \frac{1}{4\pi\varepsilon_0}\frac{Q}{r^2}$$  I've intentionally separated the inverse square of the distance and the $4\pi$ which is, I presume, a part of the normalization factor (steradians of sphere) -- but I noticed that together they forge the area of a sphere $A_r = 4\pi r^2$. This way, I could see the expression as the uniform charge density distribution on the surface of a sphere, scaled by the vacuum permittivity.  $$E = \frac{Q}{A_s\varepsilon_0}$$  And then, due to presumed uniformity, by multiplying by an arbitrary area, I could get the flux, the amount of charge(?) flowing through a particular surface in unit time(?):  $$\Phi = E \cdot A = \frac{Q}{A_s\varepsilon_0} A $$  I could see that as flux, but I'm really not sure can I really reinterpret parts of the normalization factor and the inverse-square of the distance into the area of a sphere. From the perspective of voltage over distance it makes absolutely no sense to me.  Any help would be appreciated.


Every now and then when I am working on a model this happens    Why has it become a different color and then when I import it into UE4 they are see through can i fix this or is this some sort of bug?

While rendering a mesh with smooth shading on, I get a dark region/shadow on certain faces. The effect is more evident when smooth shading is applied to a mesh containing ngons, with the ngons turning black when rendered.   The blackening effect is visible in the viewport too.  How can I solve this problem?


I have a question regarding my specific case and how long I may stay in Europe on my American passport. I am a student and am currently finish a term in London. During the term, I have spent a total of 17 days in the Schengen area (not sure if it's relevant to figuring out the calculation, but the first day I entered was 11th February). On 24th May, I will be entering again and staying until 11th July (49 days). From there I will be traveling to Ireland for about a week, but return to the Schengen area from 19th-28th July (10 days). I will then be spending another week in England. These dates are set in stone due to a variety of reasons that have to do with meeting friends and family in various places. I will be beginning another term in Spain on 30th August, but will of course be able to enter Spain at that time with the visa that I will have obtained.   The question is this: how much of the period from 4th-30th August will I legally be allowed to spend inside the Schengen area? Again, between 11th February and 27th July I will have spent a total of 76 days there. Any help you can give would be extremely helpful. To be clear, I've done a lot of reading here and on other sites to try to find my answer without posing a question myself, but most other Schengen questions seem to be from people who have had to obtain Schengen visas prior to travel, and I'm not sure whether this alters things. Thanks in advance!

I have searched the web a lot and could not find an answer that fits my situation. Here are two links that are quite contradictory:       My situation:  I've visited Portugal in December 2012 for 29 days on a Schengen visa valid from December 1st, 2012 to February 1st, 2013 for research purposes (I am a Ph.D. student). I want to visit Sweden from February 10th, 2013 to May 10th, 2013 (89 days). I have applied for a Schengen visa again (for research). How will the 90/180 rule work in my situation?


find the number of ordered triples $(x,y,z)$ satisfying $$x\mid yz-1$$ $$y\mid xz-1$$ $$z\mid xy-1$$ and $0<x,y,z<2014$  note: $x,y,z$ are integers  I found $(2,3,5)$ as one set of solution (actually $6$), and I tried change $$x\mid yz-1\Longrightarrow xk_1=yz-1$$but it didn't work.  Any idea/hint of how can I make progress?  Thank you in advance.  Note:I DO NOT want a computer testing all combinations.

If $p,q,r$ are all primes,and $p|qr-1$$~~~~~~~~~~~~~$$q|pr-1$$~~~~~~~~~~$ and $~r|pq-1$. Find all possible values of $pqr$.    My work: $qr-1=pk_1$ $pr-1=qk_2$ $pq-1=rk_3$ From the above equations, we can conclude that either $k_1,k_2,k_3$ are all even or one of the primes is $2$. I can also get that, $p^2q^2r^2=(pk_1+1)(qk_2+1)(rk_3+1)$ Now, I cannot proceed. Please help!


I'm doing a constrained optimization problem, but I want to know how this equation is derived. I understand it is made up of the Lagrangian multiplier, the original equation, and the constraint, but I want some intuition on how it works. $$\mathcal{L}(x,y,\lambda) = f(x,y) - \lambda g(x,y).$$

I've always used the method of Lagrange multipliers with blind confidence that it will give the correct results when optimizing problems with constraints. But I would like to know if anyone can provide or recommend a derivation of the method at physics undergraduate level that can highlight its limitations, if any.


I just want a book on classical mechanics that covers the same ground as Goldstein's book but is more on the line of DJ Griffiths's Classical Electrodynamics. I mean less formal and more conversational.

I'm a bachelor student majoring in math, and pretty interested in physics. I would like a book to study for classical mechanics, that will prepare me to work through . What books would be good for a beginner?


I'm curious if there is actually a term for what I have just deemed "the disparate clarification" -- for example I just saw a tweet that said "Let's party, and by party I mean scramble to figure out how to go to Mexico for cheaper healthcare." I think these types of sentences (not the content here) with such irrelevance are so funny but I don't know what they're called/ if there is a term !

Consider this conversation:      John: I am giving free chess lessons.   Mary: Nice! You’re a true teacher.   John: How so?   Mary: A true teacher imparts knowledge without a price tag.   John: But what if teaching is his only source of income? Would he not be a “true” teacher then?   Mark (in response to the question above): You clearly mentioned “free chess lesson”.   I don’t see how Mark’s comment adds anything to the discussion or makes sense in the current discussion. It is “redundant” — that’s one word for it — but is there a more fitting word?


given a TextBlock with multiple Runs, how can I specify a relative FontSize? For example, if the TextBlock has FontSize 10, I would like one of the Runs to be 15. But if the FontSize becomes 20, I would like the Run to become 30.

I am creating a custom WPF control that let's say for simplicity sake has a vertical stack panel with a "title" TextBlock, followed by a ContentPresenter. I want the font size for the "title" to be 5 Points LARGER than the size used in the content, which is inherited by whatever container the user places this control in.  How can I specify a font size in the control template for the header element using a relative value without exposing a property like "TitleFontSize" to the user? I want do "add 5".  I tried using a ScaleTransform on the header text block with mixed results (the text block scaled fine but the orientation was modified - I had the text right-justified and it moved "off the control" area when scaled). Also, I am not sure if scale transform would be approprite here.


Looking for an algorithm that will give me the number of members that will result from calculating a Fibonacci series, given a particular limit.   For example, if I start the series at 1 and limit my results to <= 10000, determine the number of members such a Fibonacci series will contain. (I am writing some software that builds a Fibonacci series to a given limit: Before the calculation begins, it would be more efficient to know in advance how much memory I need to allocate for a container that will hold all the resulting members of the series)

Assuming I'm asked to generate Fibonacci numbers up to N, how many numbers will I generate? I'm looking for the count of Fibonacci numbers up to N, not the Nth number.  So, as an example, if I generate Fibonacci numbers up to 25, I will generate:   1, 1, 2, 3, 5, 8, 13, 21 that's 8 numbers   How do I calculate this mathematically for an arbitrary "n"?


I want to make available a pool of dev machines to a pool of developers, where each developer should only access its own dev machine. Dev machines are on a private network, behind a NAT, whereas developers are on the DMZ.  I'd want to implement a solution in which:   users connect via ssh (X forwarding included) to the NAT public interface, which in turn forwards the request to an Access Control machine (basically a proxy); the AC machine forwards the connection to the right dev machine, depending on a configurable policy.   Clearly, users should neither know about target machine name or IP nor guess the network structure. They should only initiate an SSH connection without any client-side special configuration (this prevents the use of ProxyCommand).  How can I implement such a solution?

Has anyone done SSH proxying that is transparent to the user, but the end host they are routed to is determined by any of the following:  username, identity key, DNS hostname.  I guess DNS hostname isn't possible with the protocol, but it could use the identity key.  For example, I want users to be able to all SSH to the same machine, but they end up on different VPS nodes:  ssh -i identity_rsa user@example.com.    There are a few very nice features of doing this:   The RSA host key is the same no matter what VPS you SSH into.   The hostname could be the same, or (dubious) it could route on subdomain names.  I'm not sure if this is in the protocol or it only uses the IP address to connect to a TCP socket. Zero configuration on the client side (proxy commands, multiple ssh tunnels, etc) All traffic is funneled through a gateway.   I'm worried this requires a custom (legitimate) MitM SSH server, because I want a normal end-to-end SSH connection that can do SCP and agent-forwarding.    Can agent forwarding work with forced commands?  Could I create forced commands based on the public key, call SSH -A to the inside host?


I am currently having outrageous vertical space before and after I use align.   For a bit of context, I used \onehalfspacing to make my document a bit clearer. However, it becomes ugly when I using align. For instance, here is a picture of what it looks like compared to when I am using array (and in fact any time I need to write maths using "$$") :     I would like to reduce this white space when I use align, but I can't find anything relevant enough. Since I am searching for something that works anytime without always repeating the command each time I have to use align, I was thinking of creating a new environment, but I don't know how to make one like align.   Thanks a lot for your help !   EDIT : Here is the code I used to take the picture :   \documentclass{article} \usepackage[utf8]{inputenc}  %---------------  \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc}  \usepackage[french]{babel}  \usepackage[cyr]{aeguill}   %---------------   \usepackage{fancyhdr} \usepackage[top=3cm, bottom=3cm, left=3cm, right=3cm]{geometry} \usepackage{setspace}   %---------------  \onehalfspacing  %\setlength{\parskip}{0cm} %not usefull  %---------------   \usepackage{amsmath, amssymb, amsthm}  \usepackage{mathrsfs} \usepackage{etoolbox} \usepackage{stmaryrd}  \title{Tests Overleaf} \date{\today}  \begin{document}  \maketitle  \section{Introduction}  ------------------------------------------------------------------------------------------  I am using array :   $$\begin{array}{cccccc}     f : & A & \times & B & \longrightarrow & C \\     & x & ; & y & \longmapsto & xy  \end{array}$$  ------------------------------------------------------------------------------------------  I am using align* :   \begin{align*}     a \times (b+c) & = a \times b + a \times c\\     & = a \times b + a \times c + 0 \end{align*}  ------------------------------------------------------------------------------------------  \end{document}

How could I go about setting the 'above' and 'below' vspaces around the equation environment?  If the same could be done for the subequations or gather environments, this would be a bonus.


I found this differential equation $$ f''(x) = f^{-1}(x) $$ which is interesting to me. I wonder if there is a calculus oriented way to solve this differential equation. Is there some method to to solve differential equations containing inverse of a function ?

What are some good examples of a function  $f : \mathbb{R} \to \mathbb{R}$ where its derivative is equal to its inverse? I attempted to find a monomial that satisfied it by starting with $f(x) = ax^b$ and showing that $f^{-1}(x) = f'(x) \implies b-1=\frac{1}{b} \implies b=\phi$ and got $$f(x) = \frac{x^\phi}{\sqrt[\phi]{\phi}}$$ Which seems to work according to WolframAlpha, but I'm having trouble double-checking it. Any other ideas?


My laptop model is DELL INSPIRON 15z(has 2 hard drives. One is 500GB HDD and the other is 32GB mSATA used for caching purpose and fast booting using IRST). I want to dual boot ubuntu alongside windows 8 that is currently installed on it. But I am not getting the option to install ubuntu alongside windows. Last time when I tried to install ubuntu my windows crashed.  Please help me out with detailed instruction.

I'm absolutely new to Linux. I would like to know how to install Ubuntu alongside the pre-installed Windows 8+ OS.  Should I do it with Wubi, or through the Live USB/DVD?  What steps do I need to take to correctly install Ubuntu?


Let $X$ be a topological space, and let $\{U_i\}$ be an open cover. If $Y$ is subset of $X$ such that $Y\cap U_i$ is closed in $U_i$ (for each $i$), does this imply that $Y$ is closed in $X$?

If I want to show a topological subspace is closed in an ambient space, does it suffice to know what happens on an open cover of the ambient space? More specifically,     Let $X$ is a topological space with a given open cover ${ U_i }$. Suppose that $Z \subset X$ is a set such that $Z \cap U_i$ is closed in $U_i$ for all $i$. Does it follow that $Z$ is closed in X?   This is clearly true if there are finitely many ${ U_i }$. At first thought, it seems unlikely to be true in the infinite case, but I'm having trouble coming up with a suitable counter-example.


Give a solid cube of uniform mass distribution and total mass $M$. I want Moment of Inertia of this cube about an axis passing through its centre and perpendicular to one of its faces where a is the lenght of side of cube? I tried taking a cuboidal volume element of length $a$, breadth $dy$ and height $a$ and integrating it over entire length of cube but I reach with an answer that moment of inertia $I = Ma$ but I know $I = M\frac{a^2}{6}$. What am I doing wrong?

How do I calculate the moment of inertia of a uniform solid cube about an axis passing through its center of mass?  I also wanted to know if the moment of inertia of a body is independent of its shape. Also, recently I read somewhere that the moment of inertia of a  uniform solid cube is minimum about an axis passing through its COM because the mass is more concentrated at its center. Does the statement make any sense?


Gyros with an analog interface represent rotational velocity by a varying DC voltage. The range of my gyro woks from -10 V DC to +10 V DC. I need a circuit to convert this range into this range: from 0 v DC to 5 V DC.   Example:   Gyro OUTPUT   -9 v DC      Circuit OUTPUT    0.25 v DC. Gyro OUTPUT   -8 V DC      Circuit OUTPUT    0.50 v DC Gyro OUTPUT   -+5 v DC     Circuit OUTPUT    3.75 V DC Gyro OUTPUT   +10 v DC     Circuit OUTPUT    5.00 V DC   How to do it?

Can anyone explain how one would convert one voltage range to another? I'm going to need to convert a range of -10 to +10 volts into a range of 0 to +5 volts. How would this be accomplished? Thanks!   Let me say  something more. Inside of a torpedo there are gyroscopes. This gyroscope give -10 volts when the torpedo have 180 degrees of deviation to the west and 10 volts when the deviation is to the east. This signal is DC, so i need to change this range a range: 0 to 5 v DC . Thanks


After doing a regular update using Software Updater, Ubuntu froze and stopped responding to any input from keyboard. I tried to do a fresh restart, but now I cannot go beyond the blinking cursor and black screen that does not respond to any input from keyboard.  I tried to use Live CD and here are the outputs.  sudo fdisk -l /dev/sd?  Disk /dev/sda: 149.1 GiB, 160040803840 bytes, 312579695 sectors Units: sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disklabel type: dos Disk identifier: 0xc8019649  Device     Boot     Start       End   Sectors   Size Id Type /dev/sda1  *           63 308512003 308511941 147.1G 83 Linux /dev/sda2       308512260 312576704   4064445     2G  5 Extended /dev/sda5       308512323 312576704   4064382     2G 82 Linux swap / Solaris  Disk /dev/sdb: 7.5 GiB, 8004304896 bytes, 15633408 sectors Units: sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disklabel type: dos Disk identifier: 0x0002f0af   sudo blkid  /dev/sdb1: LABEL="UBUNTU 16_0" UUID="96E9-5126" TYPE="vfat" PARTUUID="0002f0af-01" /dev/loop0: TYPE="squashfs" /dev/sda1: PARTUUID="c8019649-01" /dev/sda5: PARTUUID="c8019649-05"   sudo blkid -c /dev/null -o list  /dev/loop0 squashfs         /rofs           /dev/sda1                   (not mounted)   /dev/sda5                   (not mounted)   /dev/sdb1  vfat    UBUNTU 16_0 /cdrom      96E9-5126   It is clear that there is a problem with the partitioning of the hard disk. What can I do to fix it?  Edit: I tried to use Boot-Repair (see ) but the problem still persists!

I was trying to resize my EXT4 partition and something went wrong. I lost it. The space in once consumed is now being represented as Unallocated. How do I recover the partition?


I have a friend from Russia who wants to visit the UK on a 90 day visa. what is the minimum amount she needs to prove her solvency

I am an Indian citizen studying in Italy on an Italian visa that expires 19 November, 2015. I have permesso di soggiorno. I want to visit the United Kingdom for my vacations for a week during March. I know the procedures already, however I am a little bit confused about the amount that I must show as a proof of support with my bank statements. I will stay for a week with my friends who are also students in Italy and will be in London for 5 days. What would be the amount in Euros that I need to show for my visit to UK?


Show that if $a$ and $b$ are positive integers then $(a, b)=(a + b, [a, b])$.  I was thinking that since $[a, b]=LCM(a, b)=\frac{ab}{(a, b)}$ that if $d= (a + b, [a, b])$, then $d|[a,b]$ and thus $d|(a, b)$ since $(a, b)|[a, b]$  Then I would just have to prove that $(a+b, (a, b)) = (a, b)$.  Is that the right way to go?

Show that if $a$, $b$ are positive integers, then we have: $\gcd(a,b) = \gcd(a + b, \mathrm{lcm}[a,b])$.


I have a Shapefile with Polygon features  representing the world's land areas (continents, islands).   Is it possible to invert these, and get a geometry that represents the world's oceans and seas?   So the original land Polygons need to become rings in a single global Polygon that covers the planet.  Basically, I'm looking for something like Select > Inverse in Photoshop.   I am using QGIS.

I'm using python in QGIS. I have a layer of polygons (its a result of some earlier dissolving and has no overlapping polygons but some holes and islands in holes etc). I want to build a new layer which contains one polygon representing a bbox of the first layer with each polygon cut from it.  Essentially I want to "invert" the layer I have so that where the was polygon, now there is not, and where there was not polygon now there is. All inside a bounding box of the original layer.  I can build a bbox easily and I tried to "subtract" the polygon layer from my new bbox polygon layer but the process slows to a stop and then crashes my PC. Here's the algorythm  processing.runalg("qgis.difference","path/to/polygon.shp","path/to/bbox.shp","path/to/result.shp")   I dont care about attributes (obviously). I just need to cut one set of polygons from one larger polygon.  It seems so simple, I wish I could find a simple command or script to acheive this. As stated at the top I'm looking for a solution in python in QGIS.


For the following example, where we have "\" at the end, the \ and EOL character should be removed.  line 1\ line 2 line 3 line 4\ line 5   Output should be  line 1 line 2 line 3 line 4 line 5   Using vi, I can get above stuff as under: :%s/\//n//g  But when I do it on the terminal is not working. Any suggestions?

Using a common command line tool like sed or awk, is it possible to join all lines that end with a given character, like a backslash?  For example, given the file:  foo bar \ bash \ baz dude \ happy   I would like to get this output:  foo bar bash baz dude happy


I'm using fedora 25 gnome latest update. My dnf repo list is  fedora-cisco-openh264.repo  rpmfusion-free-updates.repo fedora.repo                 rpmfusion-free-updates-testing.repo fedora-spotify.repo         rpmfusion-nonfree-rawhide.repo fedora-updates.repo         rpmfusion-nonfree.repo google-chrome.repo          rpmfusion-nonfree-updates.repo rpmfusion-free.repo         rpmfusion-nonfree-updates-testing.repo   Yesterday I updated my system using dnf. Today gnome software center notified me that 19 packages need to be updated. I tried to update using dnf because I hate updating using the software center since it requires restart but couldn't find any update using dnf update.  So I updated fedora using gnome software center, it installed a buggy gdm version, couldn't log in, had to use tty to login, then startx.  I do sudo dnf distro-sync then dnf deletes and downgrades all updates that gnome software center had installed, I reboot and everything works.  Gnome software center is a mastery to me, not the fist time I ask about it on this site. Is it trustworthy? Do its repos conflict with dnf?

During a Gnome session I received an upgrade notification from Software Update so I switched to a tty (I never run 'dnf upgrade' inside an X session) to run the update but 'dnf upgrade' shows that no updates are available. The Software Update gui clearly shows a higher version for the new packages but a 'dnf list updates' does not display them.  Can someone tell me what I am doing wrong? Is the gui tool using different repositories?


I have created a variable $JAVA_HOME in `/etc/environment'  JAVA_HOME="/usr/lib/jvm/jdk" PATH="...bla bla bla:$JAVA_HOME/bin"   I also edited /etc/profile to have source /etc/environment so that all users get Java home. and the directory itself has been made 755 for access.  The printout as root for env:  LANG=C.UTF-8     SUDO_GID=1000 USERNAME=root JAVA_HOME=/usr/lib/jvm/jdk SUDO_COMMAND=/bin/su USER=root PWD=/home/ssuser HOME=/root SUDO_USER=ssuser SUDO_UID=1000 MAIL=/var/mail/root TERM=xterm SHELL=/bin/bash SHLVL=2 LOGNAME=root PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:$JAVA_HOME/bin   But when I do the same as ssuser without sudo-ing, the environment variable $JAVA_HOME is expanded to the actual path.   SSH_CONNECTION=193.128.134.115 18497 10.1.4.4 22 LESSCLOSE=/usr/bin/lesspipe %s %s LANG=C.UTF-8 JAVA_HOME=/usr/lib/jvm/jdk XDG_SESSION_ID=2 USER=ssuser PWD=/home/ssuser HOME=/home/ssuser SSH_CLIENT=193.128.134.115 18497 22 XDG_DATA_DIRS=/usr/local/share:/usr/share:/var/lib/snapd/desktop SSH_TTY=/dev/pts/0 MAIL=/var/mail/ssuser TERM=xterm SHELL=/bin/bash SHLVL=1 LOGNAME=ssuser XDG_RUNTIME_DIR=/run/user/1000 PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/usr/lib/jvm/jdk/bin LESSOPEN=| /usr/bin/lesspipe %s   And this has nothing to do with what's set in /etc/sudoers for env_var reset/keep settings. Because I have tried this in a different computer and it works just fine.   I am slightly clueless as to why this is happening. Also, something very strange I have noticed is that for a single session sudo users aren't being prompted for password. I have checked /etc/sudoers and it is set up correctly to ask password for root.  I have tried closing the session and reopening. I can see as them as a normal user, not root. Also, rebooting doesn't do anything different.

I changed the /etc/environment to add more directories to the PATH variable. But looks like $PATH in double quotes were not expanded and I could find any command from the shell and /usr/bin/command-not-found is run.  $ cat /etc/environment  PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games" PATH="$PATH:/home/user/technical/java/maven/bin" JAVA_HOME="/home/user/technical/java/jdk7"   so from the tty,  $ echo $PATH $PATH:/home/user/technical/java/maven/bin   why did not the expansion happen?


I'm a Syrian citizen, travelling from Paris to Turkey and Saudi Arabia. Do I need a Turkish visa? I have valid residency in Saudi Arabia and a Schengen visa.

I have an Indian passport and am planning to visit Germany with a valid visa. To book a flight for Germany (Mumbai – Dusseldorf), I came across some connected flights that stop at Istanbul.  Do I need to have visa for Turkey?  This is the first time I am travelling outside my country, and any information on this will be helpful.


I tried the method here   But it failed. Patch 12 has been out for a while now. Does ubuntu plan to have it included in the apt update etc?  If not, could I please be advised of how to update to the latest patch?  Thank you

Today a couple of buffer overflows in NTP were announced , . It looks like updating my system to fix these issues is in order.   How can I find out if they have been fixed in the Ubuntu repositories, such that if I were to run:   sudo apt-get update sudo apt-get upgrade   then the fix would get installed and the vulnerability closed?   Edit: The selected answer specifically addresses the question of how to identify if a given CVE has been fixed or not, "Does Ubuntu generally post timely security updates?"  is certainly related but not identical


I got as far as   $$|z-2i|=3|z+3| \Leftrightarrow \\  (\ldots) \Leftrightarrow \\ x^2-y^2+4y-4=9x^2+54x+81-9y^2 \Leftrightarrow \\ x^2-9x^2-y^2+9y^2+4y-4-54x-81=0\Leftrightarrow \\ -8x^2+8y^2+4y-85-54x=0 \Leftrightarrow \\ 8y^2+4y-8x^2-54x-85=0\Leftrightarrow \\ y^2+\frac{1}{2}y-x^2-\frac{27}{4}x=\frac{85}{8}$$  Then I tried to complete the square:  $$y^2+\frac{1}{2}y = 0\Leftrightarrow (y+\frac{1}{4})^2-\frac{1}{16}$$  $$-x^2-\frac{27}{4}x=0 \Leftrightarrow -(x+\frac{27}{8})^2+\frac{729}{64} = 0 \Leftrightarrow (x+\frac{27}{8})^2-\frac{729}{64} = 0$$  And so the equation becomes:  $$(y+\frac{1}{4})^2-\frac{1}{16}+(x+\frac{27}{8})^2-\frac{729}{64}=\frac{85}{8} \Leftrightarrow \\ (y+\frac{1}{4})^2+(x+\frac{27}{8})^2=\frac{85}{8}+\frac{1}{16}+\frac{729}{64} $$  According to my book the center is $-\frac{27}{8}-\frac{1}{4}i$ which I got right but the radius is $\frac{\sqrt{117}}{8}$.  What went wrong?

I tried:  $$|z-2i| = 2|z+3| \Leftrightarrow \\ |x+yi-2i|=2|x+yi+2|\Leftrightarrow \\ \sqrt{x^2+(y-2)^2}=\sqrt{4((x+2)^2+y^2)} \Leftrightarrow \\ \sqrt{x^2+y^2-4y+4} = \sqrt{4x^2+24x+36+4y^2} \Leftrightarrow \\ x^2+y^2-4y+4 = 4x^2+24x+36+4y^2 \Leftrightarrow \\ y^2-4y-4y^2=4x^2+24x+36+x^2 \Leftrightarrow \\ -3y^2-4y=5x^2+24x+26 \Leftrightarrow \\ ???$$  What do I do next?


Now I'm refactoring some code and I found something weird.  I thought the following 2 expressions were exactly same:  list1 = [[0.00] * 5 for _ in range(5)] list2 = [[0.00] * 5] * 5   I can see they make same results by running:  print(list1 == list2)   or  import numpy as np print(np.array(list1).shape == np.array(list2).shape)   But in the project I'm revising, list2 doesn't work. When I use it, it raises 'Index out of range'.  Please tell me if 'list1 == list2' as I said, or if I'm wrong about that.  Thanks in advance.  P.S. I can use numpy.zeros() or some other things, but I'm really curious.

I needed to create a list of lists in Python, so I typed the following: my_list = [[1] * 4] * 3  The list looked like this: [[1, 1, 1, 1], [1, 1, 1, 1], [1, 1, 1, 1]]    Then I changed one of the innermost values: my_list[0][0] = 5  Now my list looks like this: [[5, 1, 1, 1], [5, 1, 1, 1], [5, 1, 1, 1]]    which is not what I wanted or expected. Can someone please explain what's going on, and how to get around it?


I have the following code (based on  answer):  #include <iostream> #include <vector>  class Debug { public:     template <typename T, typename A>     static void printVector(const std::vector<T,A>&, const std::string& = "Vector:"); };  template <typename T, typename A> void Debug::printVector(const std::vector<T,A>& v, const std::string& message) {     std::cout<<message<<std::endl;     for(auto item : v)     {         std::cout<<item<<std::endl;     } }  int main() {     std::vector<std::string> vec {"a","b","c"};     Debug::printVector(vec);     return 0; }   It works great in an . However, when I try to compile it with GCC 4.8 on Ubuntu, it says:  error: undefined reference to `void Debug::printVector<std::string, std::allocator<std::string> >(std::vector<std::string, std::allocator<std::string> > const&, std::string const&)' error: collect2: error: ld returned 1 exit status   Without the template (using simply std::vector<std::string>) everything works fine.

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.)


I have 2 projects in one solution in Visual Studio, one in C++ talking to some hardware, one in C#, building a GUI and such.  In my .cpp I have some functions that work:  namespace ISCOPumpLibrary {     char data[512];      bool ISCOPump::Connect(char unit, int com, long baud) {         commport = com;         speed = baud;         unitnum = unit;          connected = commOpen(commport, speed);         return connected;     }      bool ISCOPump::GetInfo() {         char in[512], out[512];          in[0] = 'G';          Execute(in, out);         strcpy_s(data, out);          return true;     }   With a .h file like:  namespace ISCOPumpLibrary {     public ref class ISCOPump     {     public:          static bool Connect(char unit, int com, long baud);         static bool GetInfo();   These are called in the C# program as follows:  private void Button_GetInfo_Click(object sender, EventArgs e) {      bool connected = ISCOPumpLibrary.ISCOPump.Connect(7, 7, 19200);     bool info = ISCOPumpLibrary.ISCOPump.GetInfo();      //label_serial.Text += "\r\n" + info; }   This all seems to work. The problem I'm having is I cannot seem to find a way that actually works to return the char data[512] or char out[512]  I've looked through a bunch of answers but can't find one that looks similar to my case, most seem to be calling these things a little differently.  I've tried using std::string or having an argument of char*, and haven't had any luck getting C# to like either of those.  Any ideas on how I should get this to work?  Solution header:  namespace ISCOPumpLibrary {      using namespace System::Runtime::InteropServices;     using namespace System;      public ref class ISCOPump     {     public:         // ISCO Implemented functions.          //returns success bool         static bool Connect(char unit, int com, long baud);          //returns string of info         static bool GetInfo([Out]String^ %c);   cpp:  namespace ISCOPumpLibrary {     bool ISCOPump::Connect(char unit, int com, long baud) {         commport = com;         speed = baud;         unitnum = unit;          connected = commOpen(commport, speed);         return connected;     }      bool ISCOPump::GetInfo([Out]String^ %c) {         char in[512], out[512];          in[0] = 'G';          Execute(in, out);          c = gcnew String(out);          return true;     }   cs:      private void Button_Connect_Click(object sender, EventArgs e)     {          bool connected = ISCOPumpLibrary.ISCOPump.Connect(7, 7, 19200);          ISCOPumpLibrary.ISCOPump.GetInfo(out string data);          label_serial.Text += "\r\n" + data;     }   Note one of the key details was that the using namespace system calls in the header had to be within the class to prevent all sorts of conflicts.

I have a function which parses one string into two strings.  In C# I would declare it like this:  void ParseQuery(string toParse, out string search, out string sort) {     ... }   and I'd call it like this:  string searchOutput, sortOutput; ParseQuery(userInput, out searchOutput, out sortOutput);   The current project has to be done in C++/CLI.  I've tried  using System::Runtime::InteropServices;  ...  void ParseQuery(String ^ toParse, [Out] String^ search, [Out] String^ sort) {     ... }   but if I call it like this:  String ^ searchOutput, ^ sortOutput; ParseQuery(userInput, [Out] searchOutput, [Out] sortOutput);   I get a compiler error, and if I call it like this:  String ^ searchOutput, ^ sortOutput; ParseQuery(userInput, searchOutput, sortOutput);   then I get an error at runtime.  How should I declare and call my function?


I can't seem to get my program to loop properly. So, the goal is that after the user input their numerical grade, it will output the corresponding letter grade. After that, the user is prompted whether or not they would like to go again, in which they can enter "y" or "Y" to continue. At this point, however, even when entering "y" or "Y", the program will not loop.  //Grades.java by Jonathan Holter 02/01/2015  import java.util.*; public class Grades { public static void main(String args[])  {     int numGrade = 0;     String againRun = "y", letterGrade = "A";      Scanner keyboard = new Scanner(System.in);     System.out.print("\nWelcome to Jonathan Holter's Grade Converter" + "\n--------------------------------------------");      while(againRun == "Y" || againRun == "y")     {         do         {             System.out.print("\n\nEnter the numerical grade: ");             numGrade = keyboard.nextInt();             keyboard.nextLine();              if(numGrade < 0 || numGrade > 100)             {                 System.out.print("\nERROR: Out of Range" + "\nPlease choose a value between 0 - 100");             }         }         while(numGrade < 0 || numGrade > 100);          if(numGrade < 60)         {             letterGrade = "E";         }          else if(numGrade > 59 && numGrade < 70)         {             letterGrade = "D";         }          else if(numGrade > 69 && numGrade < 80)         {             letterGrade = "C";         }          else if(numGrade > 79 && numGrade < 90)         {             letterGrade = "B";         }          else if(numGrade > 89 && numGrade < 101)         {             letterGrade = "A";         }          System.out.print("\nLetter Grade: " + letterGrade);          System.out.print("\n\nContinue? <Y/N> ");         againRun = keyboard.next();      }   }   }

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 tried some advice , but it doesn't work. I want window opacity be changed on mouse wheel or on shortcut pressed (like in KDE).

I notice Xubuntu can let me change the opacity of inactive windows, which seems nice for having small videos playing while showing my terminal below. But it quickly gets annoying when doing anything else – I don't want every inactive window transparent, and I'd rather not go into settings all the time to turn it off. Can I just set it for one window?  (Bonus points for turning it into a script that can both set transparancy, always-on-top, and remove window decorations)


I have submitted an article (media and communication studies) to a ScholarOne journal. The paper was accepted with minor revision (two reviewers both recommended 'minor revision'). I revised the paper accordingly and addressed the feedbacks. After submitting the revised article for a week, a ADM was assigned and the status has changed to "awaiting reviewer invitation." This status has not been changed for a month. Now, the status has changed to "Awaiting Reviewer Scores." Does it really mean that my paper will go through another round of review with new reviewers? I was told that for paper with "minor revision," it is likely like it will not be sent back to the reviewers. Has anyone experienced similar situation? I have posted before and received answers saying that "Awaiting Reviewer Invitation" can mean "With Editor." But since the status is now "Awaiting Reviewer Scores", does it mean that my paper has been sent for another around of review? Thank you!

What steps does a manuscript typically go through from submission to publication (or rejection) in a typical journal? How are these steps referred to, in particular by editorial systems, and how long do they each typically take?  Note that this question is about the typical situation and hence not about:   Journals with an atypical workflow, e.g. those that allow for an instantaneous reviewer–author interaction. Exceptional steps or rare occurrences such as withdrawal or .   This is a canonical question on this topic as per . Due to its nature, it is rather broad and not exemplary for a regular question on this site. Please feel free to improve this question.


I try to adjust the right margin of a cventry for the ModernCV template to match with the overall right margin but it is always broader (see screenshot). I tried geometry package and minipage but both have not solved the problem. Here is example code: \documentclass[11pt,a4paper,sans]{moderncv}  \moderncvstyle{banking}  \moderncvcolor{black}  \usepackage[utf8]{inputenc}  \usepackage{enumitem}  \usepackage[official]{eurosym}   \name{David}{Doe} \usepackage[scale=0.9]{geometry} \begin{document} \section{Employment} \begin{itemize} \item{ \cventry{11/2019 - current}{Hello}{Hello}{Hello}{}{\vspace{0pt} \begin{itemize}[label=$\bullet$]  \item{XXX} \end{itemize}} }  \end{itemize}  \end{document}


Please send me _ how to ? I don't want to lose info stored on lost phone

My phone got stolen yesterday. The problem is that all phone numbers are in it, and I don't know any numbers now. I tried many different solutions to get my contacts to PC.  Google I went into my Gmail account, and on the left side of the screen selected Contacts > My Contacts, but none of my phone contact's names or numbers are there. Only the e-mail contacts are there with the e-mail addresses.  Bluestacks I installed Bluestacks on my PC, managed to login with my Google account, but the contacts are not there, and most of the apps require SMS verification.   Is there any way that I recover the contact information from my phone?


Why is there not yet a solution for notifications from favorite posts, because I think it's a great feature most people wanted?  I think it just completes the favourite option. Why is it taking too long for this feature? Are there any semantic problems? What is the status of this feature?

We're considering adding favorite notifications to the global inbox, and are looking for feedback on the idea (as we're not completely sold on it).  But first, some history.  Favorites are kind of like bookmarks, in that they're kept in a handy centralized place.  They also follow you across browsers.  Ok, ok... "bookmarks, on the internet" is not the most compelling feature, but Favorites also opted you into notices for those questions as if you were the owner (edits and new answers, at least).  This was probably the most confusing part (though a  feature) of the old envelope behavior judging by erroneous bug reports, so a way to opt out of this .  Now, favorite updates go nowhere.  But we could* put them into the inbox.  Here's how we envision this feature working:   Every current user has their "notify me on favorite changes" preference cleared (new users start with it cleared). The first time someone favorites a question, they're prompted to opt-in to favorite notices. Whenever a question is commented on or answered (or, possibly, edited) a new notice is pushed into the inbox of users who have favorited it, and have opted in.   Opt-in would be per-site, and it would remain possible to opt-out from your profile page.   This is not a final design, but the basic idea is correct  As I mentioned above, we're not 100% sold on this idea.  We've had a policy to date that nothing goes into the inbox that isn't specifically targeted at a user; this would be tweaking that policy.  *We could also put changes into their tab on the user page, but that reduces their visibility.


I am trying to retreive a value from a JSONObject using optString and match it with a string value, but it never matches, though the values are the same. What am I doing wrong? if (jsonServerOP.optString("Code", "") == "0") {  // condition is successfull     // This never runs, even if the server returns the Code '0' }  Server returns this JSON: { "Code":"0", "A":"LBEN", "LBEID":"3", "LBEIDI":"23" }


Let $f$ be defined for all real $x$ and suppose that $|f(x) - f(y)| \leq |x - y|^{1+ \alpha}$ for all real $x$ and $y$, where $ \alpha > 0$.  Prove that $f$ is constant.  Proof:  I shall show that the derivative of $f$ is zero.  We have that $0 \leq | {f(y) - f(x)} | \leq |x-y|^{1+ \alpha}$. Dividing through by $|x-y|$ we have $0 \leq |\frac{f(y) - f(x)}{y - x}| \leq |y - x|^{\alpha}$ and letting $y \rightarrow x$, we have shown that $f'(x) = \lim_{x \to y}|\frac{f(y) - f(x)}{y - x}| = 0$.  Therefore $f$ is a constant.

I want to show that if a function $f:[a,b]\rightarrow \mathbb R$ satisfies a Hölder condition of order $\alpha > 1 $ then it is constant.  The way I think of it is as follows:  $$|f(x) - f(y)| < K|x-y|^\alpha$$  $$\frac{|f(x) - f(y)|} {|x-y]}  < K|x-y|^{\alpha -1}$$  $$\lim_{y\rightarrow x} \frac{|f(x) - f(y)|} {|x-y]} \le \lim_{y\rightarrow x}  K|x-y|^{\alpha -1} =0 $$ As the limit is $0$, we can remove the modulus, so we get:  $$\lim_{y\rightarrow x} \frac{f(x) - f(y)} {x-y} = 0$$ So $f$ is derivable and $f'(x) = 0$ for all $x$ in $[a,b]$. Note that the reason we can add the limit $y\rightarrow x$ is because $[a,b]$ is closed in $\mathbb R$.  However, the question gives as a hint using the mean value theorem. I am not sure why one should do that. You would first have to prove that $f$ is derivable in a similar manner to what I did, and then prove that $f$ is constant. Or is there a simpler way to do it and I am missing it?  Also please inform me of any mistakes I did in the proof (if any)/ Thank you!


I am trying to figure out if there is a way in powerpoint when i am using "" i can make the vertical height of a shape fix and if the text in a shape can't fit that the shape only grows horizontally.  Is this possible as it seems like the default behavior is to grow only vertically

I have a shape (rounded rectangle) in PowerPoint 2007 of which I would like to increase the vertical size only (to illustrate de-bottlenecking). So, the width will stay the same but the height will grow (both from the top and bottom, so the centre will remain in the same location).  Custom Animation -> Emphasis only appears to change the whole shape.  Is it possible to increase only the vertical size (stretch the shape)?  This is during animation of the shape.


I am implementing the routing machine wich is leaflet extension for routing analysis but by default the routing in routing machine is for demo based on OSM data.I want my own route ;How I do to build my OSRM server for route and how I make route of public transport based on bus lines not roads .

I have my own routing server that uses OSRM as an routing engine. (I used .)  I want to be able to add my own data (roads) and include that data in the routing.  So in the beginning I thought to add my data in the OSM format (node, way, relation) with an id that doesn't exist in the xml file to the osm.xml file that the OSRM uses to route. But that will mess up the id's coming from the OSM server in case of updating the data (diff).  So now I'm wordering if there is any way to use OSRM with my own data.


How to convert javascript Object to Json format?  I can create object data when user submit the form and i dont know how to convert submit data like json format?  can you tell me how to do?  here is my sample code..,    Example    "cashpayments": [ {   "name": something,   "email": something,   "password": null }]                        <<<<< --- LIKE THAT --- >>>>>     (function ($) {     $.fn.serializeFormJSON = function () {          var o = {};         var a = this.serializeArray();         $.each(a, function () {             if (o[this.name]) {                 if (!o[this.name].push) {                     o[this.name] = [o[this.name]];                 }                 o[this.name].push(this.value || '');             } else {                 o[this.name] = this.value || '';             }         });         return o;     }; })(jQuery);  $('form').submit(function (e) {     e.preventDefault();     var data = $(this).serializeFormJSON();     console.log(data); });  <form action="#" method="post">
         Name         <input type="text" name="name" id="name" />

         Email         <input type="text" name="email" id="email" />

         Password         <input type="password" name="password" id="password" />

         <input type="submit" value="Send" />
 </form>

I need to  an object to . I'm using . Is there a "standard" way to do this?  My specific situation: I have an array defined as shown below:  var countries = new Array(); countries[0] = 'ga'; countries[1] = 'cd'; ...   and I need to turn this into a string to pass to  like this:  $.ajax({     type: "POST",     url: "Concessions.aspx/GetConcessions",     data: "{'countries':['ga','cd']}", ...


In the UK at the moment there's some controversy regarding the changing of the timing of the Covid vaccination boosters. All the vaccines I can think of that need boosters are given to babies, whose immune systems aren't fully developed yet. So they get some protection initially but need a booster when they're more mature. Are there any vaccines given to adults that actually need a booster? Was it used in the Covid trials for a good reason, or just to make doubly sure the results would be good? The information I can find online only covers the standard childhood vaccinations, and similar questions on this forum by other people over the past few years have remained unanswered.

It has been suggested by my employer that i should get the Hepatitis B vaccine to protect myself.  I have had two of the three parts, but this is the first time i have had a vaccine in more than one session.  The vaccine is in 3 doses, each around a month apart, followed up by a blood test.  Why is the Hepatitis B vaccine split into 3, any what is the blood test for at the end?


Wasn't there a Programmers Stack Exchange site? A site different from Stack Overflow, of course. I don't see it listed.

I can't find the "Programmers" site anywhere and haven't seen the "Software Engineering" site before - is it the replacement of "Programmers"?


For three continuous verbs, which is right?     1a. Please can you help make the bed.      1b. Please can you help making the bed.      2a. An advisor can help expanding the width.      2b. An advisor can help expand the width.      3a. He can help come up with great ideas.      3b. He can help coming up with great ideas.

Help my sister peel oranges. Help my sister to peel oranges. Help my sister peeling oranges.  Help my sister with peeling oranges.   Which of the above is/are correct, and why are the others incorrect?


I am a totally new to beamer and I just can't seem to figure out why beamer won't let me include equations.  I run the following code and it does not work. I try to include {equation*} but it still does not work.  Any help would be appreciated  \documentclass{beamer} %%%%%%% \begin{document} %%%%%%% \begin{frame} \frametitle{Modified CAPM }  \begin{equation}% \begin{split} R-Rf& =\alpha_1EU+\alpha_2US+\beta_1MktRf+\beta_2EUFund*MktRf+\epsilon \end{split} \end{equation}  \end{frame} \end{document}   Also it does not work when I update the code to simply:  \documentclass{beamer}  \begin{document} \begin{frame} R-Rf=\alpha_1EU+\alpha_2US+\beta_1MktRf+\beta_2EUFund*MktRf+\epsilon \end{frame} \end{document}

I have this problem where I can't built slide documents with beamer every time I include a math environment as simple as $\mu = A$. The log file posts this message at the end:  !pdfTeX error: miktex-pdftex.exe (file mathkerncmssi10): Font mathkerncmssi10 a t 657 not found  ==> Fatal error occurred, no output PDF file produced!   I understand that the file (mathkerncmssi10) that is apparently missing is part of the package sansmathaccent, but the package is already there and updated.  This is driving me crazy, I would appreciate any help.    Sure, I tried this with several examples. I can post this one  \documentclass{beamer} \usepackage[latin1]{inputenc} \usetheme{Warsaw} \title[Make a LaTeX presentation using Beamer]{Introduction  to Beamer\\How to make a presentation with LaTeX?} \author{Nadir Soualem -- Astozzia} \institute{Math-linux.com} \date{Jule 13, 2007} \begin{document} \begin{frame} \titlepage \end{frame} \begin{frame}{Introduction} This is a short introduction to Beamer class. $\mu=A$ \end{frame} \end{document}    By the way, it turns out that I just tried this one in another PC and works fine.


I posted on  and someone suggested I post on  instead. I wanted to look up the scope and guidelines for each of the two sites, but in the Android app I could not find them.

There's no help in Help in Android app. Nothing about how to use the app. Maybe the link should be called 'About'. Going to meta is not real documentation.


It is possible to show so-called dotfiles/directories like .git or files/directories that have the Hidden attribute in the Finder by running   defaults write com.apple.Finder AppleShowAllFiles 1   from the command line (then running killall Finder to restart it). However, this only works in Finder, not in applications' Open/Save dialogs. In those, one can use the ⌘⇧. keyboard shortcut to show these files, but you have to use it each time you open a new dialog as the settings aren't saved.   Does anyone know of any kind of way to make this setting permanent? It could involve a Terminal command, editing a .plist or other file on an application by application basis, anything.  was asked a while ago with no satisfactory answers, so I'd like to see if there have been any changes in Mountain Lion, or if anyone knows an answer that just missed the first question. I'm currently running 10.8.4, if it makes any difference.

I have a folder that starts with a dot . but am unable to display it in Finder. How can I say that for folder x, Finder should also display hidden files/folders?


Is there a way to ssh to my server and execute command automatically. To ssh to the server I open cmd then type putty -load "saved_session" to load my saved session(). is there a way I can add a command that will execute automatically after I ssh ?

I often find myself opening an SSH session to run the same single command. I have everything setup to login without entering a password (Via SSH Key-Based Auth), so I wondered if there was a way to create a shortcut or a batch file in Windows that would load PuTTY or a similar program, then fire off that command (and likely exit if result is good).


I could just do it via usb but why the hassle if you don't have too, any reason why it wouldn't just be offering the update?

I'm following the , but on launching the upgrade tool I get this response:  Checking for a new ubuntu release No new release found   Am I doing something wrong? Is there a workaround?


There are two numbers $\log_3 4$ and $\sqrt[4]{2}$. How they can be compared without calculator?

Both $\log_34$ and $2^\frac 1 4$ are somewhere in between $1$ and $2$. I know I can get approximate values but they are difficult to calculate by hand so I conclude it's not the way I'm supposed to do the exercise.  So how can I compare the two numbers without using a calculator?


Can someone help me utilize native wordpress jquery to run my function? The only working test i have done is to load an external jquery resouce via the chrome dev console and then add my function to the inspect element console.  WORKING TEST: add this to the console:  if(!window.jQuery||confirm('Overwrite\x20current\x20version?\x20v'+jQuery.fn.jquery))     (function(d,s){s=d.createElement('script'); s.src='https://ajax.googleapis.com/ajax/libs/jquery/1.8/jquery.js'; (d.head||d.documentElement).appendChild(s)})(document);   THEN ADD MY FUNCTION TO THE CONSOLE:  $(function() {     var $sidebar   = $("#post-43 > div > div > div.row.caldera-clarity-row.caldera-clarity-row-1 > div.caldera-clarity-column.col-sm-3"),          $window    = $(window),         offset     = $sidebar.offset(),         topPadding = 15;      $window.scroll(function() {         if ($window.scrollTop() > offset.top) {             $sidebar.stop().animate({                 marginTop: $window.scrollTop() - offset.top + topPadding             });         } else {             $sidebar.stop().animate({                 marginTop: 0             });         }     }); });   THE QUESTION: Can you help me achieve the same functionality by way of Wordpress' native jquery library? The function just needs to work on the /Lessons page.  I am unsure if my function is supported by native wp jquery or if i'm just incorrrectly adding it to the page.  Assume that i have read these 2 articles: code.tutsplus.com/articles/the-complete-guide-to-proper-javascript-usage-with-wordpress--wp-32172   Thanks so much,

I know that jQuery is loaded, because I can switch out the $ for 'jQuery' and everything behaves as expected, but this will be a messy script if I can't fix this  This script:  jQuery(document).ready(function(){     $("ul.vimeo_desc_feed li a").click(function(){         alert($(this).attr('href'));         return false;     }) });   Produces the error $ is not a function  This script:  jQuery(document).ready(function(){     jQuery("ul.vimeo_desc_feed li a").click(function(){         alert(jQuery(this).attr('href'));         return false;     }) });   works fine.


Google says I need to “verify” my account. I don’t want to give up my phone number to Google. Are there any ways to bypass this? I’ve already tried changing my IP address.  It doesn’t matter how I register with Google, through Gmail, or from an Android device. They still ask for phone verification. Nothing works. I tried throwaway numbers, but apparently Google made sure to blacklist all numbers from VOIP services.

When I want to register an account with Gmail now, it says "Google will send a text message containing a verification code to your mobile phone."  I don't want to give Google my mobile phone number!!  How do I get around this?


I try to edit a photo in Photoshop by just dragging it in, the image is too small so I transform it to make it large enough to fit the screen. It shows a nice picture but whenever I deselect, it looks awful and sharpening tools don't work. I need help.

How to resize an image or selection without resampling the pixels? I have some pixel art that I want to enlarge without losing the hard, non-anti-aliased, pixel edges. In other words, 1px should become 4px of the same color— fake big pixels. Is there any way to achieve this procedurally?  Example (of what I don't want):  before resize:    after resize:    Open to other tools/methods beyond photoshop, thanks in advance.


For this problem, I found a very complicated solution. Are there any easier methods? I am asking mainly because the final answer was what I intuitively guessed before solving the problem. It is also surprising that after so much work I get such an intuitive result.  Problem: John keeps rolling a standard six-sided dice until it comes up as a 6. What is the expected number of dice rolls?  My Solution: The probability that John rolls only once is $\frac{1}{6}$. The probability that John rolls twice is $\frac{5}{6}\cdot\frac{1}{6}$. The probability that John rolls three times is $\frac{5}{6}\cdot\frac{5}{6}\cdot\frac{1}{6}$. Seeing the pattern, the probability that John rolls $k$ times is $\frac{1}{6} \cdot \left(\frac{5}{6}\right)^{k-1}$. We verify this by adding all $k$ from $1$ onwards to $\infty$ and checking if that is $1$. This works because positive integers are the only number of times that John can roll. $$\sum_{n=1}^{\infty} \frac{1}{6} \cdot \left(\frac{5}{6}\right)^{i-1} = 1$$What we want is the sum of the arithmetico-geometric sequence $$\sum_{n=1}^{\infty} \frac{i}{6} \cdot \left(\frac{5}{6}\right)^{i-1} = \hspace{1mm}?$$To get a better idea of what this sequence is, we expand out a few terms. $1 \cdot \frac{1}{6} + 2 \cdot \frac{5}{6}\cdot\frac{1}{6} + 3 \cdot \frac{1}{6} \cdot \left(\frac{5}{6}\right)^{2} + \cdots$. Now we factor the initial term, $\frac{1}{6} \left(1 + 2 \cdot \frac{5}{6} + 3 \cdot \left(\frac{5}{6}\right)^{2} + \cdots \right)$. We let $S = 1 + 2 \cdot \frac{5}{6} + 3\left(\frac{5}{6}\right)^{2} + \cdots$. We can now use the trick for any geometric sequence on this sequence. $\frac{5}{6}S = \frac{5}{6} + 2\left( \frac{5}{6}\right)^2 + 3\left(\frac{5}{6}\right)^{3} + \cdots$. Subtracting the second equation from the first gives us $\frac{1}{6}S = 1 + \frac{5}{6} + \left(\frac{5}{6}\right)^2 + \left(\frac{5}{6}\right)^3 + \cdots$. This leads to $S = 36$. The expression we want is $\frac{S}{6} = \boxed{6}$  Edit: My question is different than the other one because I am asking for an explanation on why the answer is the intuitive one and if there are any better methods to solve while that question is only asking for the answer.

Given a discrete random number generator, such as a six-sided die, what is the expected value of the number of rolls necessary to roll a specific number (e.g. a six)?   I think the result should be given by E$\langle$rolls$\rangle$ = $\frac{1}{6}\sum_{n=0}^\infty{(\frac{5}{6})^n(n+1)}$, but I don't know how to calculate the convergence of that sum.  Also, how do I calculate the variance?


Is it normal for a journal submission to show “With Editor” for more than forty days?

What steps does a manuscript typically go through from submission to publication (or rejection) in a typical journal? How are these steps referred to, in particular by editorial systems, and how long do they each typically take?  Note that this question is about the typical situation and hence not about:   Journals with an atypical workflow, e.g. those that allow for an instantaneous reviewer–author interaction. Exceptional steps or rare occurrences such as withdrawal or .   This is a canonical question on this topic as per . Due to its nature, it is rather broad and not exemplary for a regular question on this site. Please feel free to improve this question.


In a bash shell, consider this: $ x="-name 'foo bar'" $ find $x find: paths must precede expression: `bar'' $ find -name 'foo bar' ./foo bar  What can I put in $x to make find $x behave like find -name 'foo bar'?

$ ls -l /tmp/test/my\ dir/ total 0   I was wondering why the following ways to run the above command fail or succeed?  $ abc='ls -l "/tmp/test/my dir"'  $ $abc ls: cannot access '"/tmp/test/my': No such file or directory ls: cannot access 'dir"': No such file or directory  $ "$abc" bash: ls -l "/tmp/test/my dir": No such file or directory  $ bash -c $abc 'my dir'  $ bash -c "$abc" total 0  $ eval $abc total 0  $ eval "$abc" total 0


I have watched many physics debated and in everyone of them, physicists take big bang for granted. But, is the big bang actually proven, or there are many evidence that indicate that it did happen?

Ok so the universe is in constant expansion, that has been proven, right? And that means that it was smaller in the past.. But what's the smallest size we can be sure the universe has ever had?  I just want to know what's the oldest thing we are sure about.


I was watching CNN's coverage of the earthquake that struck northern California this morning, and I heard the following exchange between the CNN anchor and a seismologist, Walter Hays:  ANCHOR: This is 6.1 on the Richter scale, that means ... one-tenth the power of the one that struck in '89? HAYS: No, that's the confusion ... It's nearly thirty times mo—weaker. It's one-thirtieth of the Loma Prieta earthquake.  (Emphasis mine.) As it happens, this touches on a longstanding peeve (and I am perfectly willing to describe it as such) that I have about the use of positive multipliers to describe the lack of something: twice as small, three times colder. In everyday use, of course, this pattern is readily understood as indicating the reciprocal of the opposite quality: something that's thirty times weaker is actually one-thirtieth as strong. It was interesting to hear Mr. Hays catch himself making the mistake, and then correct himself using more formally precise language—something I think a scientist would be more likely to do than a layperson. So my question is: Is this really a mistake, or is it actually semantically proper/meaningful to use language indicating a positive magnitude to characterize a concept that is defined specifically as a lack of something else? We don't have a problem using ordinary intensifiers and superlatives in such contexts: a thing can be very small or much weaker. It seems intuitive to me that a multiplier should be treated differently from an intensifier, but I can't actually define why that should be the case. What about the reverse: if twice as small is semantically proper, what about half as small (the obvious ambiguity notwithstanding)? Or are these all more properly thought of as physics or mathematics questions, rather than language questions?

I’m not sure of whether this is grammatically correct, although I've encountered the same expression many times before.     Most Google searches show it produces 35 times less carbon than the report suggested.   Does 35 times less have a precise meaning in this context, or is it ambiguous here? Does either of these two possibities apply?   the original amount minus 35 times the original amount (35 times less than 100 units would be −3400 units) ¹⁄₃₅ of the original amount (35 times less than 100 units would be  2 ⁶⁄₇ units)


People like myself are Stack Exchange trusted users with thousands of reputation points and hundreds of badges.  In other words, we've proven ourselves as people who are assets to Stack Exchange and are a key component in making it so profitable.  As such, I was surprised when I posted  on the  site, and then shortly afterwards tried to  on that same meta site, but was blocked with a message in red stating I had to wait 40 minutes before posting again.  Why is this limit present for trusted Stack Exchange contributors, and can it be changed?

I am registered on about 80 SE sites, am an "avid user"(>200 rep) on about 30, and a modest user (103-199 rep) on about 20 more.  Once when I tried to ask a question on Open Data (my "new user" site), the "systemwide" 40 minute rate limit kicked in. So I asked on meta , given that my previous post on the site was days ago. So a mod commented by telling me about the systemwide post rule and asking me if I had just come from another site. I said, yes, History (my best site, 40K rep.)  I can see why I would be rate limited on Open Data. I can understand that I would be rate limited if I had come from say, Open Source, another site where I'm a new user. But did the system "rate limit" me as a new user on one site, based on my activity on History, an "established" site?  Also, about the one day new user rate limit after a question is downvoted: Suppose a question on the previous site receives two upvotes and one downvote (net of one upvote). Is that a different situation than receiving one down downvote and no upvotes? Or does the downvote count in both cases, including the one where there were offsetting upvotes? How about if the downvoted question on the previous site was deleted?  I don't have this problem when going from one "established" (greater than 125 rep) site to another. I understand why a person would be "rate limited" going from one new site to another; SE wants people to ask questions 40 minutes apart on their new sites. In my case, I was blocked when I left an "established" site (my best) to go to a new site, which is almost the same as going to a new site de novo.  Why would this be? Or can't the system tell that my "first" site was an established site? Would I have been similarly rate limited if I went first to the "new" site, and 39 minutes later to the established site? Or does the rate limit apply only when the "destination" site is the new site?  Put another way, there are four permutations of established and new sites: 1) established to established 2) new to new 3) established to new and 4) new to established. The block doesn't apply in the first case, does apply in the second case, and apparently applies in the third. What about the fourth? And why? Because it is not "uniform" across sites in the four cases.   Edit: Unlike the other question, this one is not about the general rule. It is about the "special case" described in the paragraph above.


Whilst thinking of a trick where a magician pulls a tablecloth directly from under a full set dinner (a classic) I wondered why friction doesn't increase as speed does. I get that they use a pretty sleek table cloth but even still I don't see how friction doesn't stop this motion even further, for instance the quicker one speeds around a race track, the quicker the tires bald. Is it perhaps the traction of the two which has this effect of decreasing friction or is there another force in play?  ( if you think this question is off topic or unnecessary to the general public, just tell me so and I will edit it or delete it if need be, please do not vote as off topic or the like)

Does the force of kinetic friction increase with the relative speed of the objects involved?    I have heard and read that the answer is no.  This is counter intuitive, and is a big part of why the "Airplane on a Treadmill" question is so interesting.  What phenomena are at work with kinetic friction, and why does it not increase with relative speed?