I have been googling (and SO-ing) for a while but haven't come across a single article/answer pointing me at the right Java class to extract a MD5 hash from a file and convert it to armored ascii.   It seems impossible to me that such a thing doesn't exist.   Please note that what I mean is something such as MessageDigest.getInstance("MD5").fromFile("C:\My\Path\file.txt").digest().toBase64(); or something to this effect.  What am I missing?
I am looking to use Java to get the MD5 checksum of a file.  I was really surprised but I haven't been able to find anything that shows how to get the MD5 checksum of a file.  How is it done?
How to convert strings into integers in Python? I have a tuple of tuples from a MySQL query like this:  T1 = (('13', '17', '18', '21', '32'),       ('07', '11', '13', '14', '28'),       ('01', '05', '06', '08', '15', '16'))   I'd like to convert all the string elements into integers and put them back into a list of lists:  T2 = [[13, 17, 18, 21, 32], [7, 11, 13, 14, 28], [1, 5, 6, 8, 15, 16]]   I tried to achieve it with eval but didn't get any decent result yet. How do you make an image emission without washing out the image? Do redirection operators always open file descriptors in parallel? 1. Consider snippet#1:  $ cat test.txt &gt; test.txt cat: test.txt: input file is output file   It seems that cat makes its input file descriptor point to test.txt and then when it tries to set its output file descriptor to test.txt it throws the above error. Here it seems that cat is aware of the redirect operator and so proceeds to attempt to set the output file descriptor to test.txt  2. Consider snippet#2:  $ cat 1.txt 1:CAT 2:dog $ sed 's/cat/CAT/g' test.txt 1:CAT 2:dog $ sed 's/cat/CAT/g' test.txt &gt; test.txt $ cat test.txt # Note that test.txt is now empty $   Here we see that sed opens test.txt (last argument) in read mode and at the same time sets test.txt as its file output descriptor. Also the '&gt;' operator overwrites the contents of the file BEFORE sed starts to read from it.   I am aware that commands in a pipeline execute in parallel but have not come across any info on how redirection operators behave. Any supporting links would be helpful. Proof that a sum of Bernoulli rvs has Binomial distribution Let $\{X_n, n \geq 1\}$ be iid Bernoulli random variables with $\Pr(X_1 = 1) = p = 1 - \Pr(X_1 = 0)$ and let $S_n = \sum\limits_{i=1}^n X_i$ be the number of successes in $n$ trials. Show $S_n$ has a binomial distribution by the following methods:  1.) Prove for $n\geq0,$ $1\leq{k}\leq{n+1}$  $$\Pr(S_{n+1} = k) = p\Pr(S_n = k - 1) + q\Pr(S_n = k)\text{ where }q = 1-p.$$  2.) Solve the recursion using generating functions.  For the first method, I think I need to use convolution of $n + 1$ Bernoulli rvs, but I cannot immediately see the progression. For the second method, I don't exactly understand how to proceed either. This is problem 1.2 from Resnick's Adventures in Stochastic Processes. Even though JRE 8 is installed on my MAC OS Yosemite, the error - " No Java Runtime present,requesting to install " Why are cryptography algorithms not exported to certain countries? There have been strict laws about the export of crypto software to certain countries. I can understand the intent, but never gauged the fact that there is nothing stopping these countries from developing their own crypto software. So why limit the export?   And in light of the recent NSA revelations, of backdoors being engineered into crypto algos, wouldn't the export of such compromised algorithms have helped to unravel secrets? When I have .txt files or .py files, I can Quick Look those files in Finder. I have .jl files that are codes written in the Julia Language. Of course they are text files. They will open in a text editor like Sublime Text. How can I Quick Look these .jl files in Finder? Basic buoyancy question: Man in a boat with a stone This comes from a brain teaser but I'm not sure I can solve it:     You are in a rowing boat on a lake. A large heavy rock is also in the boat. You heave the rock overboard. It sinks to the bottom of the lake. What happens to the water level in the lake? Does it rise, fall or stay the same?   I'd say that the water level drops, because when you drop the stone in the lake, the water level rises according to the volume of the stone, BUT the water level decreases by a volume of water weighting the stone's weight, when you take it off the boat.  Is that correct? Switches needed in an n-location multiway switching system we can construct a two location multiway switching system with two 3-way switches:    They also teach us how to perform three location multiway switching with two 3-way switches and one 4-way switch:    Is it possible to make a similar system (three locations, all able to switch the light in any situation) with only three 3-way switches?   What can be said in general about the switches needed to make an n-location multiway switching system? Cannot find Underground Jungle Temple On my 1.2 Terraria Map I have been mining from left to right in my large underground jungle using my rocket launcher. Despite this, I have had no luck on finding the Underground Jungle Lihzahrd Temple. I have been searching the layer above where lava constantly spawns. Have I simply spawned in a world without one or am I searching in the wrong place? I have also considered using the clentimator with Dark Blue ammo to provide light, should I do that? Show that $\langle 2,x \rangle$ is not a principal ideal in $\mathbb Z [x]$ Hi I don't know how to show that $\langle 2,x \rangle$ is not principal and the definition of a principal ideal is unclear to me. I need help on this, please.   The ring that I am talking about is $\mathbb{Z}[x]$ so $\langle 2,x \rangle$ refers to $2g(x) + xf(x)$ where $g(x)$, $f(x)$ belongs to $\mathbb{Z}[x]$. Mail vs. mail what is the difference What is this business about mail and Mail? [On a CentOS box] Why mail does not work but won't return an error either while Mail works fine with the exact same syntax?  Mail is basically a link to mail, isn't it?  Sorry, this was a mixup, apparently (for historical reasons?!) there is a mail and a Mail  Nowadays it looks like they both point to the same thing, on my machine:  sr-linux&gt; ls -l `which mail` -rwxr-xr-x    1 root     mail        66492 Jun 24  2001 /bin/mail sr-linux&gt; ls -l `which Mail` lrwxrwxrwx    1 root     root           14 Nov 19  2001 /usr/bin/Mail -&gt; ../../bin/mail A complete ring with respect to an ideal I would like to know what does it mean to say " a ring $R$ is complete with respect to some ideal $I \subset R$.  Is it like, we define a metric by saying two elements in $R$ is "close" if the difference lies in a higher power of $I^n$ and $R$ is a complete metric space? How to Convert 0 to 10V analog signal to 0 to 2.5V for ADC input? I have an analog signal which ranges between 0V and 10V.  I want to linearly scale it down to 0 to 2.5V for my ADC.     I'm concerned that using a resistive voltage divider will affect signal quality.  Is this true?  If it's not true, what value resistor should I use for voltage divider? How to create a bootable USB with multiple ISO images in it What I want is to create a bootable pen drive that shows GRUB menu and I can select any of the several bootable systems from there to install/run. I have several ISO images that I want to install in the USB like Ubuntu, Fedora, System Rescue CD, Windows XP and Windows 7 (The windows versions are optional, mostly am looking for a multi installer for Linux distros, specially Ubuntu version)  The default Startup Disk Creator only works with Linux Images and only 1 at a time (At least for the mean time. If it allows more systems and multiple ISOs it would be awesome)  What method exists that I can use step by step to create a bootable USB Drive with multiple images than can be booted from the USB and selected from GRUB. It must support Windows Images and Linux Images.  Alternatively, is there also a way to have multiple versions of the Ubuntu installation ISO on same USB Drive, such as, when booting from it, I get to choose what Ubuntu version and architecture to install, for example:     BOOT MENU   Ubuntu 12.04 32 Bit   Ubuntu 12.04 64 Bit   Ubuntu 12.10 32 Bit   Ubuntu 12.10 64 Bit   UPDATE: Wanted to add that the English version for the post mentioned by daithib8 is here: Does a monk's Unarmored Movement speed increase apply to the fly speed gained from a Fly spell? First of all, I think this question is not duplicated, because I have tried all other solutions I found here, but nothing solved my problem.  I use Ubuntu 14.04 64 bit.  I have tried until now: sudo apt-get install skype -> It didn't work. The error was:   The following packages have unmet dependencies: skype : Depends: skype-bin E: Unable to correct problems, you have held broken packages.   I have tried sudo dpkg add-architecture &amp;&amp; sudo dpkg -i skype-ubuntu-precise_4.3.0.37-1_i386.deb but it didn't work either. The error was:  dpkg: dependency problems prevent configuration of skype: skype depends on libqt4-dbus (&gt;= 4:4.5.3); however: Package libqt4-dbus is not installed. skype depends on libqt4-network (&gt;= 4:4.8.0); however: Package libqt4-network:i386 is not installed. skype depends on libqt4-xml (&gt;= 4:4.5.3); however: Package libqt4-xml:i386 is not installed. skype depends on libqtcore4 (&gt;= 4:4.7.0~beta1); however: Package libqtcore4:i386 is not installed. skype depends on libqtgui4 (&gt;= 4:4.8.0); however: Package libqtgui4:i386 is not installed. skype depends on libqtwebkit4 (&gt;= 2.2~2011week36); however: skype depends on libstdc++6 (&gt;= 4.2.1); however: Package libstdc++6:i386 is not installed. skype depends on libx11-6; however: Package libx11-6:i386 is not installed. skype depends on libxext6; however: Package libxext6:i386 is not installed. skype depends on libxss1; however: Package libxss1:i386 is not installed. skype depends on libxv1; however: Package libxv1:i386 is not installed. skype depends on dpkg: error processing package skype (--install): dependency problems - leaving unconfigured Processing triggers for hicolor-icon-theme (0.13-1) ... Processing triggers for gnome-menus (3.10.1-0ubuntu2) ... Processing triggers for desktop-file-utils (0.22-1ubuntu1) ... Processing triggers for bamfdaemon (0.5.1+14.04.20140409-0ubuntu1) ... Rebuilding /usr/share/applications/bamf-2.index... Processing triggers for mime-support (3.54ubuntu1) ... Errors were encountered while processing: skype   I have tried to use after sudo apt-get -f install but it didn't solve the issue.  I have tried to install by using Gdebi. The error was:  Cannot install 'libqtwebkit4:i386'   I have tried to install using Ubuntu Software Center. The error was:  Cannot install 'libqtwebkit4:i386'   I have tried changing the server in "Software and Updates". I have tried to use "Main Server" and "Servers for United States". But it couldn't solve my problem.  Anyone has any idea how to solve that?  SOLVED  Well, I formatted my pc and I installed Skype first of all. Probably another installation that I had done before the Skype installation was the problem, i guess.  Thanks people! Where can I get the original Unix? Where can I get the original Unix (from the year 1969)? I would like to look at the source code of the original Unix. How to prevent a scrollview from scrolling to a webview after data is loaded? How can I vertically align elements in a div?