Somewhat new to Linux. Starting out to get into nitty gritty details. See a lot of ttys in /dev. What are they and what do they do? I do know that tty stands for teletype but nothing beyond that.
I've been reading the  and it mentions about virtual terminals which, if I understood it correctly, it is a Linux-specific feature (not in Unix) to allow multiple login consoles in a non X11 system. You create virtual terminals by pressing ALT-F2. I'm running Linux Mint and in my /dev folder though I see many tty devices and I don't know what they are for. Here is the grepped output:  crw-rw-rw-  1 root tty       5,   0 Jan  2 19:45 tty crw--w----  1 root tty       4,   0 Jan  2 19:10 tty0 crw-rw----  1 root tty       4,   1 Jan  2 19:10 tty1 crw--w----  1 root tty       4,  10 Jan  2 19:10 tty10 crw--w----  1 root tty       4,  11 Jan  2 19:10 tty11 crw--w----  1 root tty       4,  12 Jan  2 19:10 tty12 crw--w----  1 root tty       4,  13 Jan  2 19:10 tty13 crw--w----  1 root tty       4,  14 Jan  2 19:10 tty14 crw--w----  1 root tty       4,  15 Jan  2 19:10 tty15 crw--w----  1 root tty       4,  16 Jan  2 19:10 tty16 crw--w----  1 root tty       4,  17 Jan  2 19:10 tty17 crw--w----  1 root tty       4,  18 Jan  2 19:10 tty18 crw--w----  1 root tty       4,  19 Jan  2 19:10 tty19 crw-rw----  1 root tty       4,   2 Jan  2 19:10 tty2 crw--w----  1 root tty       4,  20 Jan  2 19:10 tty20 crw--w----  1 root tty       4,  21 Jan  2 19:10 tty21 crw--w----  1 root tty       4,  22 Jan  2 19:10 tty22 crw--w----  1 root tty       4,  23 Jan  2 19:10 tty23 crw--w----  1 root tty       4,  24 Jan  2 19:10 tty24 crw--w----  1 root tty       4,  25 Jan  2 19:10 tty25 crw--w----  1 root tty       4,  26 Jan  2 19:10 tty26 crw--w----  1 root tty       4,  27 Jan  2 19:10 tty27 crw--w----  1 root tty       4,  28 Jan  2 19:10 tty28 crw--w----  1 root tty       4,  29 Jan  2 19:10 tty29 crw-rw----  1 root tty       4,   3 Jan  2 19:10 tty3 crw--w----  1 root tty       4,  30 Jan  2 19:10 tty30 crw--w----  1 root tty       4,  31 Jan  2 19:10 tty31 crw--w----  1 root tty       4,  32 Jan  2 19:10 tty32 crw--w----  1 root tty       4,  33 Jan  2 19:10 tty33 crw--w----  1 root tty       4,  34 Jan  2 19:10 tty34 crw--w----  1 root tty       4,  35 Jan  2 19:10 tty35 crw--w----  1 root tty       4,  36 Jan  2 19:10 tty36 crw--w----  1 root tty       4,  37 Jan  2 19:10 tty37 crw--w----  1 root tty       4,  38 Jan  2 19:10 tty38 crw--w----  1 root tty       4,  39 Jan  2 19:10 tty39 crw-rw----  1 root tty       4,   4 Jan  2 19:10 tty4 crw--w----  1 root tty       4,  40 Jan  2 19:10 tty40 crw--w----  1 root tty       4,  41 Jan  2 19:10 tty41 crw--w----  1 root tty       4,  42 Jan  2 19:10 tty42 crw--w----  1 root tty       4,  43 Jan  2 19:10 tty43 crw--w----  1 root tty       4,  44 Jan  2 19:10 tty44 crw--w----  1 root tty       4,  45 Jan  2 19:10 tty45 crw--w----  1 root tty       4,  46 Jan  2 19:10 tty46 crw--w----  1 root tty       4,  47 Jan  2 19:10 tty47 crw--w----  1 root tty       4,  48 Jan  2 19:10 tty48 crw--w----  1 root tty       4,  49 Jan  2 19:10 tty49 crw-rw----  1 root tty       4,   5 Jan  2 19:10 tty5 crw--w----  1 root tty       4,  50 Jan  2 19:10 tty50 crw--w----  1 root tty       4,  51 Jan  2 19:10 tty51 crw--w----  1 root tty       4,  52 Jan  2 19:10 tty52 crw--w----  1 root tty       4,  53 Jan  2 19:10 tty53 crw--w----  1 root tty       4,  54 Jan  2 19:10 tty54 crw--w----  1 root tty       4,  55 Jan  2 19:10 tty55 crw--w----  1 root tty       4,  56 Jan  2 19:10 tty56 crw--w----  1 root tty       4,  57 Jan  2 19:10 tty57 crw--w----  1 root tty       4,  58 Jan  2 19:10 tty58 crw--w----  1 root tty       4,  59 Jan  2 19:10 tty59 crw-rw----  1 root tty       4,   6 Jan  2 19:10 tty6 crw--w----  1 root tty       4,  60 Jan  2 19:10 tty60 crw--w----  1 root tty       4,  61 Jan  2 19:10 tty61 crw--w----  1 root tty       4,  62 Jan  2 19:10 tty62 crw--w----  1 root tty       4,  63 Jan  2 19:10 tty63 crw--w----  1 root tty       4,   7 Jan  2 19:10 tty7 crw--w----  1 root tty       4,   8 Jan  2 19:10 tty8 crw--w----  1 root tty       4,   9 Jan  2 19:10 tty9
Maximum and Minimum values for ints Move all files within subfolders to parent folder Firstly, I'm aware there are tons of similar questions, and I know because I must have tried adapting at least 5 of them, but I'm still here asking because my crappy grasp of CMD (which I actually thought I was getting good at up until this point) is frustrating me with generic, unhelpful errors, and I can't understand what part of the syntax is wrong. This is likely due to the fact that other questions deal with the folder/filename structures of their respective OPs, and when I try to adapt the code to my own folder/file structure it refuses to work. Therefore, I'm here asking for a CMD for loop solution that'll actually work for my own file and folder structure.  I have a parent folder which contains many other folders, in which there are files:  Parent Folder      Subfolder            File1            File2      Subfolder            File1            File2      Subfolder            File1            File2   ...and so on.  I'm wanting to use a CMD for loop in combination with the move command to extract all the files in the subfolders to the parent folder, leaving each subfolder empty.  When giving the CMD for loop please break down what each part of the command is doing, as this'll help make sure I understand the code and hopefully minimise the trouble I have getting it to work for myself. For each positive integer $n$, let $x_n=1/(n+1)+1/(n+2)+\cdots+1/(2n)$. Prove that the sequence $(x_n)$ converges.   This is what I have so far..  Let $\epsilon &gt; 0$ be given to us. We must show that there exists an $N \in \mathbb{N}$  such that $n\ge N \implies \left|\frac{1}{2n} - 1\right| &lt; \epsilon$. Choose $N$ to be any positive integer which is larger than $\frac{1}{\epsilon}$. (So $N&gt;\frac{1}{\epsilon}$.) Then $n\ge N \implies \left|\frac{1}{2n} - 1\right| = |\frac{1-2n}{2n}|$ When can we use 'much' in affirmative clauses? I found the below in  web-site:     We use much in questions and negative clauses to talk about degrees of something.      We don’t use much in affirmative clauses.   Also, it the same web-site, I found the following:     She runs much faster than he does.    also I noticed that some web-sites use much with affirmative clauses:     May we all be having this much fun and getting this much exercise when we're his age!    Is it Okey to use much in affirmative clauses? If yes, when can we use it? and what is the rules?  Update:  Here is another example on how often the word "much" is used  in informal style:     After much consideration I will NOT be performing at the Inauguration with my improv group Capitol Hill-arious Is there a way to create synchronization profiles for Google Chrome? For example I want to tag some of my browsers as "home browser"s and others as "work browser"s and I want:   my bookmarks to be synced with all browsers, my extensions to be synced only within browsers of the same type (home with home, work with work) One part of the render layer glowing? Show that if $f$ is integrable on $[a, b]$ then $\lvert f \rvert$ is also integrable. Hint: Show that $$U (P , \lvert f \rvert) − L(P , \lvert f \rvert) ≤ U (P , f ) − L(P , f ).$$ I have: $$U (P , \lvert f \rvert) \ge U (P , f )$$ and $$ L(P , \lvert f \rvert) \ge L(P,f)$$ Thus, $$U (P , \lvert f \rvert) − L(P , \lvert f \rvert) ≤ U (P , f ) − L(P , f ).$$ Prove that a set of connectives is inadequate It is relatively easy to prove that a given set of connectives is adequate. It suffices to show that the standard connectives can be built from the given set. It is proven that the set $\{\lor, \land, \neg\}$ is adequate, and from that set it can be inferred (applying De Morgan laws and such) that $\{\lor, \neg\}$, $\{\land, \neg\}$ and $\{\to, \neg\}$ are also adequate.  Nevertheless, I'm stuck trying to understand how to prove that a given set of connectives is inadequate. I know I have to prove that a standard connective can't be build using only the connectives of the given set, but I can't figure out how to do it.  FYI, I'm trying to prove that $\{\lor, \land\}$ and $\{\leftrightarrow, \neg\}$ are inadequate sets of connectives.  Thanks in advance. What is serial voting and how does it affect me? Disabling submit-button until the user has completed the form How do you think about disabling the submit-button until the user has completed the form or the required fields?   I find similar questions here on ux.se and somebody answered that the user will think that the form is broken or not immediately realize whats going on.  I think hiding is not that good but a disabling (e.g. grayscale, opacity, ...) plus a short text in the button would improve usability because the user realise that he still has to fill out something.  Is there anybody with experience or examples besides the usual error-messages/validation after submitting? From a paper via Schneier on Security's  (emphasis mine):  In the case of AES-128, there is no known attack which is faster than the 2128 complexity of exhaustive search. However, AES-192 and AES-256 were recently shown to be breakable by attacks which require 2176 and 2119 time, respectively. While these complexities are much faster than exhaustive search, they are completely non-practical, and do not seem to pose any real threat to the security of AES-based systems. In this paper we describe several attacks which can break with practical complexity variants of AES-256 whose number of rounds are comparable to that of AES-128.  Is the implication here that AES-192 is stronger than AES-256? If so, in simple terms, how is that possible?  The attack exploits the fact that the key schedule for 256-bit version is pretty lousy -- something we pointed out in our 2000 paper -- but doesn't extend to AES with a 128-bit key.  Again, in simple terms, what does that mean? In practice, does this mean I should drop AES-256 in favor of its 128-bit counterpart, like Schneier recommends in the comments?  That being said, the key schedule for AES-256 is very poor. I would recommend that people use AES-128 and not AES-256. Sci Fi action movie where an elite group of people control business through a game they play online The book says:     Concentration. Some spells require you to maintain concentration in order to keep   their magic active. If you lose concentration, such a spell ends.   So what happens if, for example, you are already concentrating on a spell, and cast Witch Bolt without concentrating. Would you get the initial arc of blue energy, or would it not even go off?  I am asking if you can cast a spell that says concentration without concentrating for an immediate effect. This would be useful to avoid interrupting your existing concentration. In essence, if you are concentrating on thing A (doesn't have to be a spell since other things need concentration), can you cast a concentration spell getting an immediate effect without losing concentration on thing A?  Since the definition of concentration is to keep the spell active (meaning it is already active) I would think that you would get the initial effect (if it had one) without the need to concentrate on it. Which Answer to Accept: Better Solution or Answer to Actual Question? Possible Duplicate:          I received two answers to a question I asked. One solution suggested I do things in a completely different manner than I have been. Another acknowledged that the first solution was correct but went on to explain how to do what I was asking.  Should I accept the first answer because it provides the better way of doing things or should I accept the second one because it answers the precise question that was asked? dropping trailing '.0' from floats I'm looking for a  way to convert numbers to string format, dropping any redundant '.0'   The input data is a mix of floats and strings. Desired output:  0   --> '0'  0.0 --> '0'  0.1 --> '0.1'  1.0 --> '1'  I've come up with the following generator expression, but I wonder if there's a faster way:  (str(i).rstrip('.0') if i else '0' for i in lst)   The truth check is there to prevent 0 from becoming an empty string.  EDIT: The more or less acceptable solution I have for now is this:  ('%d'%i if i == int(i) else '%s'%i for i in lst)   It just seems strange that there is no elegant way to handle this (fairly straightforward) case in python. Self-Contained Proof that $\sum\limits_{n=1}^{\infty} \frac1{n^p}$ Converges for $p > 1$ To prove the convergence of the p-series   $$\sum_{n=1}^{\infty} \frac1{n^p}$$  for $p &gt; 1$, one typically appeals to either the Integral Test or the Cauchy Condensation Test.  I am wondering if there is a self-contained proof that this series converges which does not rely on either test.    I suspect that any proof would have to use the ideas behind one of these two tests. Limit of $(\cos1/n)^{n^2}$ when $n\to\infty$ I've been trying to solve this limit: $$\lim_{n\to \infty} \left(\cos\left(\frac{1}{n}\right)\right)^{n^2}$$ I solved it using l'hopital but I have to try in another way. I tried to make the expression:  $$ \lim_{n \to \infty}\exp\left(n^2\ln\left(\cos\left(\frac{1}{n}\right)\right)\right)$$  but it didn't work out for me... Getting polygon shapefile node coordinates and point order Hi I would like to know whether the trace of the inverse of a symmetric positive definite matrix $\mathrm{trace}(S^{-1})$ is convex.  Actually I know that the trace of a symmetric positive definite matrix $S\in M_{m,m}$ is convex since we can find $B\in M_{n,m}$ such that $S=B^T\times B$ then we can write the trace as the sum of scalar quadratic forms, i.e. $\mathrm{trace}(S)=\mathrm{trace}(B^T\times B)=\sum_{j=1}^mb_j^T\times b_j$ where $b_j$ is the $j^{th}$ column of $B$.  for instance if we have  $trace([\begin{array}{cc} 1 &amp; 2  \\ 3 &amp; 4  \\ \end{array}] \times [\begin{array}{cc} 1 &amp; 3  \\ 2 &amp; 4  \\ \end{array}])= [\begin{array}{cc} 1 &amp; 2  \\ \end{array}]\times [\begin{array}{c} 1   \\ 2   \\ \end{array}]+ [\begin{array}{cc} 3 &amp; 4  \\ \end{array}]\times [\begin{array}{c} 3   \\ 4   \\ \end{array}]=30$  And so I wonder if $\mathrm{trace}(S^{-1})$ is convex too.. Expectation and variance of the geometric distribution How can one use memorylessness and the  and the  to find the expectation and variance of the geometric distribution?  I will post my own answer, but as always, that shouldn't stop anyone else from posting theirs.