Appending items to a list of lists in python
List of lists changes reflected across sublists unexpectedly
Consider a rocket in deep space with no external forces. Using the formula for linear kinetic energy $$\text{KE} = mv^2/2$$ we find that adding $100\ \text{m/s}$ while initially travelling at $1000\ \text{m/s}$ will add a great deal more energy to the ship than adding $100 \ \text{m/s}$ while initially at rest: $$(1100^2 - 1000^2) \frac{m}{2} \gg (100^2) \frac{m}{2}.$$ In both cases, the $\Delta v$ is the same, and is dependent on the mass of fuel used, hence the same mass and number of molecules is used in the combustion process to obtain this $\Delta v$. So I'd wager the same quantity of chemical energy is converted to kinetic energy, yet I'm left with this seemingly unexplained $200,000\ \text{J/kg}$ more energy, and I'm clueless as to where it could have come from. How does the garage system work in GTA V? I was surprised to only recently notice that      An object of any density can be large enough to fall within its own   Schwarzschild radius.   Of course! It turns out that supermassive black holes at galactic centers can have an average density of less than water's.  Somehow I always operated under the assumption that black holes of any size had to be superdense objects by everyday standards.  Compare the Earth to collapsing into a mere 9mm marble retaining the same mass, in order for the escape velocity at the surface to finally reach that of light.  Or Mt. Everest packed into one nanometer.  Reading on about this , it increases proportionally with total mass.  Assuming matter is accumulated at a steady density into a spherical volume, the volume's radius will only "grow" at a cube root of the total volume and be quickly outpaced by its own gravitational radius.  Question: For an object the , what would have to be its diameter for it to qualify as a black hole (from an external point of view)?  Would this not imply by definition that:   The Earth, Solar system and Milky Way are conceivably inside this black hole? Black holes can be nested/be contained within larger ones? Whether something is a black hole or not is actually a matter of perspective/where the observer is, inside or outside? Route SSH to host through interface Is it possible to route all outgoing requests for SSH (port 22) to mydynamicdns.afraid.org via wlan0 instead of eth0 when both are connected?  Since my IP is dynamic, I would like to use a name instead of IP. I've just upgraded from Ubuntu 18.04 to its newest LTS version - 20.04. While it comes with some interesting changes, the Desktop icon system was messed up in my opinion. When you hover the mouse cursor over the icons, you see a huge space marked around them that cannot be violated (as you can see in the image below) so that they need to be placed very far apart from each other.  18.04 allowed you to place icons much closer to each other and didn't have that marked space around them. This new way leaves much less space on the Desktop to organize large amounts of icons - including folders, files and shortcuts. Is there a way I can significantly reduce the size of icons and their "spaces" or go back to the old system of organizing files? On "Settings", there is a tool to change the size of Dock icons, but not of Desktop icons.  Also, every time I move or delete something, the Desktop "flashes" and the icons seem to rearrange themselves automatically, nothing of which happened in 18.04. I also can't move anything directly to the Desktop; I need to move to the Desktop folder on Nautilus. This makes me start to think about downgrading Ubuntu back to 18.04. Why would a partition be in use by the system if it isn't mounted? I've been migrating my system from btrfs to ext4 after running into performance issues with VMs. I have two hard drives in my laptop to work with. I've successfully moved my home partition, but the same steps I used aren't working for root.  Progress so far:  I've dd'd my root partition from /dev/sda3 into /dev/sdb3. I modified /etc/fstab to the following:  $ cat /etc/fstab #  # /etc/fstab: static file system information # # &lt;file system&gt; &lt;dir&gt;   &lt;type&gt;  &lt;options&gt;       &lt;dump&gt;  &lt;pass&gt; # UUID=95f13c34-96ca-49e3-bcb2-ff594df31506 /dev/sdb3               /               btrfs           rw,noatime,ssd,space_cache,discard      0 0  # UUID=0fe04f59-599f-41e2-ac30-2ad0f17a9727 /dev/sda2               /boot           ext2            rw,relatime     0 2  # UUID=44741e0f-924a-4841-80ef-2132bef84182 /dev/sda4               /home           ext4            rw,noatime,discard      0 0   and run sudo mkinitcpio -p linux. It seems to work. I'm able to boot by mounting the partition on the second disk. df shows:  $ df Filesystem      Size  Used Avail Use% Mounted on /dev/sdb3        28G   18G  9.8G  65% /   So, clearly, sdb3 is mounted, not sda3. Here's the problematic step: When I try to format sda3, which is supposedly unused, I get the following:  $ sudo mkfs.ext4 /dev/sda3 [sudo] password for stew:  mke2fs 1.42.11 (09-Jul-2014) /dev/sda3 contains a btrfs file system Proceed anyway? (y,n) y /dev/sda3 is apparently in use by the system; will not make a filesystem here!   sda3 is in use. How and why could it possibly be in use?  As per casey's comment, the output of mount:  mount | grep sd /dev/sdb3 on / type btrfs (rw,noatime,ssd,discard,space_cache) /dev/sda4 on /home type ext4 (rw,noatime,discard,data=ordered) /dev/sda2 on /boot type ext2 (rw,relatime)   As per Warwick's comment, unmounting:  $ sudo umount /dev/sda3 umount: /dev/sda3: not mounted   Mounting and umounting sda3 elsewhere works successfully, but changes nothing.  Update: More fishy behavior:  $ mount | grep sd /dev/sdb3 on / type btrfs (rw,noatime,ssd,discard,space_cache) /dev/sda4 on /home type ext4 (rw,noatime,discard,data=ordered) /dev/sda2 on /boot type ext2 (rw,relatime) $ sudo mount /dev/sda3 mnt [sudo] password for stew:  $ mount | grep sd /dev/sda3 on / type btrfs (rw,noatime,ssd,discard,space_cache) /dev/sda4 on /home type ext4 (rw,noatime,discard,data=ordered) /dev/sda2 on /boot type ext2 (rw,relatime) /dev/sda3 on /home/stew/mnt type btrfs (rw,relatime,ssd,discard,space_cache)   After mounting sda3, sdb3 is no longer mounter. Weird, huh?  As per mikeserv:  $ rmmod btrfs rmmod: ERROR: Module btrfs is in use   This is very much expected, since sdb3 is btrfs and supposed to be mounted to root. From my mkinitcpio.conf file:  MODULES="" HOOKS="base udev autodetect modconf block filesystems keyboard fsck" Groups with Same Number Of Elements and Subgroups Weapon damage bonuses and critical hits are the uses of 'bare infinitive' & 'participle' same here? I saw him sing     I saw him singing    In the first example, the verb sing is used as a bare infinitive and in the following one it is exemplified as a present participle. My question is  if both of them are expressing the same meaning? HTML 5 Video stretch How to use testfor with a mob with a two-word name? How can I test for mob who has a name with two words? For example villager named Grumpy Bill. For example I want to kill this villager.  This command   /kill @e[name=Bill]   would work just fine but when I try  /kill @e[name=Grumpy Bill]   it says "The entity UUID provided is in an invalid format"  What is the proper command for this action? Mysql Select some random rows and plus one specific row I have some conditions for some background job to run:  condition-command &amp;&amp; condition-command &amp;&amp; background-job &amp;   The problem is: I want the conditions to block until the job runs, as if I had run:  condition-command; condition-command; background-job &amp;   But it isn't a condition, if previous command fails I do not want the job to run.  I realised it is asynchronous, but it should not, in my mind the both following scripts should be the same, but they do not:  sleep 2; echo foo &amp; sleep 1; echo bar; wait   # prints foo, then bar: correct sleep 2 &amp;&amp; echo foo &amp; sleep 1; echo bar; wait # prints bar, then foo: bug   I know if I test $? variable it would work, or if I put the last one inside a subshell (but then I would lost job controls, I want to avoid daemons), but I want to know why bash make it this way, where is it documented? Is there any way to prevent this behaviour?  Edit: Chained ifs is disgusting, that is why I will not accept it as a alternative way. Edit 2: I know a subshell is possible, but it will not work for me, let us imagine I want to run a bunch of commands then wait in the end. It will be possible if i check the existence of /proc/$PID directory, but it would be a pain in the neck if there are several jobs. Edit 3: The main question is WHY bash does it, where is it documented? Whether or not it has a solution is a bonus! How to add and sync folders outside SkyDrive folder? I have folders with documents all over my hard drive, some which I would like to include in SkyDrive without moving them into the SkyDrive folder.  E.g. my SkyDrive folder is in C:\Users\Name\SkyDrive, but I have some files in C:\Users\Name\SyncMePlz that I also would like to be synced with SkyDrive so that I can reach them from other devices.  How can this be achieved? The system of equations Let $a,b,c\in \mathbb{R}$ that $a^{2}+b^{2}+c^{2}=1$. We want to find $x,y,z,w$ in the following equations:  $$\begin{align} x^{2}+y^{2}+z^{2}+w^{2}&amp;=1 \tag{1}\\ x^{2}+y^{2}-z^{2}-w^{2}&amp;=a \tag{2}\\ xw+yz&amp;=2b \tag{3}\\ yw-xz&amp;=2c.\tag{4} \end{align}$$ Expected number of rolling a pair of dice to generate all possible sums A pair of dice is rolled repeatedly until each outcome (2 through 12) has occurred at least once. What is the expected number of rolls necessary for this to occur?  Notes: This is not very deep conceptually, but because of the unequal probabilities for the outcomes, it seems that the calculations involved are terribly messy.  It must have been done already (dice have been studied for centuries!) but I can't find a discussion in any book, or on line. Can anybody give a reference? SCJP6 regex issue I'm looking to cite a number of web pages using bibtex and I was wondering if there was a specific template of the form @&lt;template name here&gt; for doing that. If you could use the following website as an example that would be great Create model from XYZ data points Are there surface-mount pin header footprints for KiCAD?