My USB was in the USB port and at the time I was copying something to my HDD I decided to cancel it. Immediately afterwards I decided to remove the USB but I forgot to press safe eject.   As a result of this, when I re-inserted my flash drive into the USB port, I saw one folder with some files in it which was one of the many folders I had on my USB, and AUTORUN.INF which wasn't there before. The rest of the files are gone.   The strange thing is that when I check the partition in Gparted it shows that my USB still have some files on it but when I decided to check for hidden files (CTRL+H) there was only one folder .Trash-1000. I also tried to recover some data via Gparted (GPart) but it didn't detect any partitions. According to Gparted the files are still there but I can't see them. I have also checked it on another distro and the results are the same. The file system on my flash drive is FAT32.  What happened to my files and how can I restore them?
I unplugged my USB stick from Ubuntu 16.04 without the save remove option, but exfat should be fine doing so. No read write was happening, the partition does not use journaling. What I end up with is an unmountable USB stick with checksum error.   What tools are there to recover the partition table or at least the data on the USB stick? What I am doing now is scanning via parted. Has anyone experienced the same problem with exfat and recovery options? Unfortunately parted probably won't detect the partition because .  I also tried to use Partition Wizard on Windows but it failed to detect anything, just showing unallocated space. How do I proceed? are there helpful tools under Windows or Ubuntu?    I also tried to use gpart -v /dev/sdb but it failed to detect anything. On OS X there is a tool called fsck_exfat, is there any on Windows?  update The disk is preinstalled with Parted Magic. After quick search no partition shows up.
Primitive of holomorphic Function $\frac{1}{z}$ on an Annulus. Given an Annulus with $A(0,r,R)$ show by considering Cauchy's Theorem for primitives that there is no holomorphic function with $f'(z)=\dfrac{1}{z}$.   I am struggling to picture this since but it seems like there are issues because $f(z)=\log z$ isn't well defined in the same range as $\dfrac{1}{z}$.  Am I looking to show that $\int_Ag(z)dz = 0$ where $g(z) = \dfrac{1}{z}$? How do I get the size of a directory on the command line? I tried to obtain the size of a directory (containing directories and sub directories) by using the ls command with option l. It seems to work for files (ls -l file name), but if I try to get the size of a directory (for instance, ls -l /home), I get only 4096 bytes, although altogether it is much bigger. Prove that T is diagonalizable if and only if the minimal polynomial of T has no repeated roots. vertical align middle in Installing Teamspeak and creating TeamSpeak3 .desktop file I am very new to Ubuntu and I want to create desktop launcher.  I have this in my TeamSpeak3.desktop in   [Desktop Entry] Name=TeamSpeak 3 Comment=TeamSpeak 3 VoIP Communicator Exec=/opt/TeamSpeak3-Client-linux_amd64/ts3client_runscript.sh Terminal=false Type=Application Categories=Network;Application; Icon=/opt/TeamSpeak3-Client-linux_amd64/styles/default/logo-128x128.png   in my ~/.local/share/applications/TeamSpeak3.desktop But I dont see it in my launcher and when I double click on it files, it just opens the text file. I even made it executable with     chmod +x TeamSpeak3.desktop  drwx------ 15 hung hung     4096 srp 16 12:29 . drwxr-xr-x  3 root root     4096 pro  9 19:22 .. -rw-------  1 hung hung   174627 srp 16 12:29 CHANGELOG -rwx------  1 hung hung   227136 srp 16 12:29 error_report drwx------  2 hung hung     4096 srp 16 12:29 gfx drwx------  3 hung hung     4096 srp 16 12:29 html drwx------  2 hung hung     4096 srp 16 12:29 iconengines drwx------  2 hung hung     4096 srp 16 12:29 imageformats -rwx------  1 hung hung   334520 srp 16 12:29 libc++abi.so.1 -rwx------  1 hung hung  1934744 srp 16 12:29 libcrypto.so.1.0.0 -rwx------  1 hung hung   746960 srp 16 12:29 libc++.so.1 -rwx------  1 hung hung  5842312 srp 16 12:29 libQt5Core.so.5 -rwx------  1 hung hung   484832 srp 16 12:29 libQt5DBus.so.5 -rwx------  1 hung hung  5683224 srp 16 12:29 libQt5Gui.so.5 -rwx------  1 hung hung  1335584 srp 16 12:29 libQt5Network.so.5 -rwx------  1 hung hung   290008 srp 16 12:29 libQt5Positioning.so.5 -rwx------  1 hung hung  3829280 srp 16 12:29 libQt5Qml.so.5 -rwx------  1 hung hung  3831288 srp 16 12:29 libQt5Quick.so.5 -rwx------  1 hung hung   234552 srp 16 12:29 libQt5Sql.so.5 -rwx------  1 hung hung   331232 srp 16 12:29 libQt5Svg.so.5 -rwx------  1 hung hung   117104 srp 16 12:29 libQt5WebChannel.so.5 -rwx------  1 hung hung 67570152 srp 16 12:29 libQt5WebEngineCore.so.5 -rwx------  1 hung hung   208344 srp 16 12:29 libQt5WebEngineWidgets.so.5 -rwx------  1 hung hung  6439120 srp 16 12:29 libQt5Widgets.so.5 -rwx------  1 hung hung  1334528 srp 16 12:29 libQt5XcbQpa.so.5 -rwx------  1 hung hung   180248 srp 16 12:29 libquazip.so -rwx------  1 hung hung    22936 srp 16 12:29 libsnappy.so.1 -rwx------  1 hung hung   111888 srp 16 12:29 libsrtp.so.0 -rwx------  1 hung hung   383072 srp 16 12:29 libssl.so.1.0.0 -rwx------  1 hung hung    51080 srp 16 12:29 libudev.so.0 -rw-------  1 hung hung     4340 srp 16 12:29 openglblacklist.json -rwx------  1 hung hung   260232 srp 16 12:29 package_inst drwx------  2 hung hung     4096 srp 16 12:29 platforms -rw-------  1 hung hung       26 srp 16 12:29 qt.conf drwx------  2 hung hung     4096 srp 16 12:29 qtwebengine_locales -rwx------  1 hung hung    19720 srp 16 12:29 QtWebEngineProcess drwx------  2 hung hung     4096 srp 16 12:29 resources drwx------  6 hung hung     4096 srp 16 12:29 sound drwx------  2 hung hung     4096 srp 16 12:29 soundbackends drwx------  2 hung hung     4096 srp 16 12:29 sqldrivers drwx------  3 hung hung     4096 srp 16 12:29 styles drwx------  2 hung hung     4096 srp 16 12:29 translations -rwx------  1 hung hung 18987008 srp 16 12:29 ts3client_linux_amd64 -rwx------  1 hung hung     1364 srp 16 12:29 ts3client_runscript.sh -rwx------  1 hung hung  2206064 srp 16 12:29 update drwx------  2 hung hung     4096 srp 16 12:29 xcbglintegrations Story where vampires are created by drop absorbed on neck? Head or tail sound fine to my ESL ears.  What's the reasoning behind the plural usage?  I looked it up on etymonline but didn't find anything interesting. Placing items before \documentclass When looking in books or at sample code, I always see \documentclass appearing first. Is that absolutely necessary?  I have created some test code which seems to compile fine:  \def\SetClass{article} \documentclass{\SetClass} \begin{document}     This is some text. \end{document}   Is there any problem with placing other items, such as \input, \usepackage, or such details before the \documentclass? Read columns from file, then column into an exsisting csv file Essentially, I have a csv file that contain multiple columns, called cols.csv  1,a,100 2,b,200 3,c,300 4,e,400   and I have a new csv file that has one column, called col.csv  f g h i   I want to copy the items in col.csv and append them to the end of each line in cols.csv so that, cols.csv now contains those  1,a,100,f 2,b,200,g 3,c,300,h 4,e,400,i   is that possible at all? i tried join, paste, nothing worked Is there any API function for shutting down Windows while installing any pending updates? How can I bootstrap? How can I bootstrap Drupal 8 from an external script?  This an example script from the .  require_once __DIR__ . '/vendor/autoload.php'; use PhpAmqpLib\Connection\AMQPStreamConnection;  $connection = new AMQPStreamConnection('localhost', 5672, 'guest', 'guest'); $channel = $connection-&gt;channel(); $channel-&gt;queue_declare('task_queue', false, true, false, false); echo " [*] Waiting for messages. To exit press CTRL+C\n"; $callback = function ($msg) {   echo ' [x] Received ', $msg-&gt;body, "\n";   sleep(substr_count($msg-&gt;body, '.'));   echo " [x] Done\n";   $msg-&gt;delivery_info['channel']-&gt;basic_ack($msg-&gt;delivery_info['delivery_tag']); };  $channel-&gt;basic_qos(null, 1, null); $channel-&gt;basic_consume('task_queue', '', false, false, false, false, $callback);  while (count($channel-&gt;callbacks)) {   $channel-&gt;wait(); }  $channel-&gt;close(); $connection-&gt;close();   Within a worker script like this, I need to be able to create nodes.  How can I bootstrap Drupal 8 in this script?  ? and  bootstraps passing a fake request to the kernel, which to me looks like a work-around.  In Drupal 7 you could do something like this, apparently.  // Bootstrap Drupal. include_once './includes/bootstrap.inc'; drupal_bootstrap(DRUPAL_BOOTSTRAP_FULL); Why is my profile messed up on a single site and how can I revert it? I was just asking a question on Gardening SE and suddenly my user name there is a25bedc5-3d09-41b8-82fb-ea6c353d75aand my picture is replaced by a Gravatar. My location is also left blank.  Here's a   Curiously, my profiles on all other sites are fine.  I don't have a separate login for SE, I log in using my Google account. Nobody other than me has access to my Google account. I use two step authentication and I can see on "recent devices" in Google that no one but me has accessed my Google account. I only access SE from home, and nobody other than me has used my devices.   I tried to edit my Gardening SE profile back to the way I want it to be and I got the following message:     Oops! There was a problem updating your profile:   Display name may only be changed once every 30 days; you may change again on Jun 20 at 10:49   I'm assuming this is because I changed the "about me" on all SE sites two days ago.  I never edit my profiles individually. I always apply changes to all sites, using the same profile on all sites.  I have certainly not made such strange (or any) edits to my profile on Gardening SE.  Why did this happen, and how can I get my proper user name and picture back on Gardening SE? Do I really have to wait for a whole month? I want to use the site, and I want them to recognize me as the user they know. I don't want to wait a whole month.  Update: The Gardening SE moderator Niall C. helped me out, and he offered the following potentially relevant information:     I changed your display name on Gardening &amp; Landscaping back to "Fiksdal". Your profile history shows that your profile image (from your headshot on imgur.com to a gravatar), email, about me also changed at the same time as your display name on May 21. It also shows that I changed your profile image to a different gravatar when I changed your display name just now... weird! – Niall C. 1 hour ago ConcurrentModificationException for ArrayList In convex optimization, the feasible region is convex if equality constraints $h(x)$ are linear or affine, and inequality constraints $g(x) \leq 0$ are convex. Does this mean that if $h(x)$ is nonlinear, then the optimization problem is non-convex? Is there any special case where $h(x)$ is nonlinear and the feasible region is still convex? Transposing rows and columns I have a file with the lines like below.  title1:A1 title2:A2 title3:A3 title4:A4 title5:A5  title1:B1 title2:B2 title3:B3 title4:B4 title5:B5  title1:C1 title2:C2 title3:C3 title4:C4 title5:C5  title1:D1 title2:D2 title3:D3 title4:D4 title5:D5  How can I achieve this?   title1    title2     title3    title4 A1         A2         A3         A4 B1         B2         B3         B4 C1         C2         C3         C4 D1         D2         D3         D4 I am relatively fresh to the DI party and am struggling to get my head around how exactly to use Dependency Injection. I understand that I can pass requirements as part of a service, but what about in my own class?  Say I have the below class where I want the language manager service to be injected:  class Foo implements ContainerInjectionInterface {    protected $languageManager;     public function __construct(LanguageManagerInterface $languageManager) {     $this-&gt;languageManager = $languageManager;   }    public static function create(ContainerInterface $container) {     return new static(       $container-&gt;get('language_manager')     );   } }   When I call new Foo() I am required to pass an instance of LanguageManagerInterface. That makes sense in terms of a normal constructor method, but that would require me to instantiate the class like the below:  $languageManager = \Drupal::service('language_manager'); $foo = new Foo($languageManager)   That just doesn't feel right to me.  Is there something I am missing, or would this class always have to be a service to take advantage of dependency injection? Does Android keep the .apk files? if so where? I am given $f,f' \in L^1(\mathbb{R})$, and f is absolute continuous, I want to show that:  $$\lim_{|x|\rightarrow \infty} f(x)= 0$$  Not sure how to show this, I know that $f(x)=\int_0^x f'(t) \, dt+f(0)$, and I can assume without loss of generality that $f(0)=0$, any help?  Thanks in advance. Canonical URL for a home page and trailing slashes Is there a name based virtual host SSH reverse proxy? I've grown quite fond of HTTP reverse proxies in our development environment and found the DNS based virtual host reverse proxy quite useful. Having only one port (and the standard one) open on the firewall makes it much easier for management.  I'd like to find something similar to do SSH connections but haven't had much luck. I'd prefer not to simply use SSH tunneling since that requires opening port ranges other than the standard. Is there anything out there that can do this?  Could HAProxy do this?