I know that similar questions have been asked () and there is also an , but I could not figure out why this is happening in my case. I get the following error when I am trying to run simple hello world program username@computer:~/hello$ cargo run    Compiling hello v0.1.0 (file:///home/username/hello)                         error: linking with `cc` failed: exit code: 1   |   = note: "cc" "-Wl,--as-needed" "-Wl,-z,noexecstack" "-m64" "-L" "/home/username/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib" "/home/username/hello/target/debug/deps/hello-48f1e5d3f3df5b46.1y16o1qfye96o7m0.rcgu.o" "/home/username/hello/target/debug/deps/hello-48f1e5d3f3df5b46.3rngp6bm2u2q5z0y.rcgu.o" "/home/username/hello/target/debug/deps/hello-48f1e5d3f3df5b46.4oc10dk278mpk1vy.rcgu.o" "/home/username/hello/target/debug/deps/hello-48f1e5d3f3df5b46.4xq48u46a1pwiqn7.rcgu.o" "/home/username/hello/target/debug/deps/hello-48f1e5d3f3df5b46.544l4wfz89vbhoea.rcgu.o" "/home/username/hello/target/debug/deps/hello-48f1e5d3f3df5b46.oa3rad818d8sgn4.rcgu.o" "-o" "/home/username/hello/target/debug/deps/hello-48f1e5d3f3df5b46" "/home/username/hello/target/debug/deps/hello-48f1e5d3f3df5b46.crate.allocator.rcgu.o" "-Wl,--gc-sections" "-pie" "-Wl,-zrelro" "-Wl,-znow" "-nodefaultlibs" "-L" "/home/username/hello/target/debug/deps" "-L" "/home/username/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib" "-Wl,--start-group" "-Wl,-Bstatic" "/home/username/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libstd-9318d1aa9575dbf9.rlib" "/home/username/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libpanic_unwind-e3cd3f44688b2d97.rlib" "/home/username/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/liballoc_jemalloc-2f4890fbea3bd5e0.rlib" "/home/username/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libunwind-a0ddde720c2c46c5.rlib" "/home/username/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/liballoc_system-9c41ffe739844496.rlib" "/home/username/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/liblibc-af766b046896c123.rlib" "/home/username/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/liballoc-00b776688b98de66.rlib" "/home/username/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libcore-d05a4396ceff8bc8.rlib" "-Wl,--end-group" "/home/username/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libcompiler_builtins-fe16a4dcdcd95bab.rlib" "-Wl,-Bdynamic" "-ldl" "-lrt" "-lpthread" "-lpthread" "-lgcc_s" "-lc" "-lm" "-lrt" "-lpthread" "-lutil" "-lutil"   = note: /usr/bin/ld: cannot find Scrt1.o: No such file or directory           /usr/bin/ld: cannot find crti.o: No such file or directory           collect2: error: ld returned 1 exit status  I have tried:  Reinstalling Rust Checking whether GCC is installed (it is) Directly compiling the file via rustc main.rs (same error)  It seems to be issue with the new Rust compiler. I am using rustc 1.29.1 (b801ae664 2018-09-20) on Linux mint 18.3 , Kernel version is $ uname -a Linux Computer 4.10.0-38-generic #42~16.04.1-Ubuntu SMP Tue Oct 10 16:32:20 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux

I'm building a project using a GNU tool chain and everything works fine until I get to linking it, where the linker complains that it is missing/can't find crti.o. This is not one of my object files, it seems to be related to libc but I can't understand why it would need this crti.o, wouldn't it use a library file, e.g. libc.a?  I'm cross compiling for the arm platform. I have the file in the toolchain, but how do I get the linker to include it?   crti.o is on one of the 'libraries' search path, but should it look for .o file on the library path?   Is the search path the same for gcc and ld?


I ran the upgrade from 14.04 to 16.04.  Ran flawlessly until very end, and I got a pop-up which said the mscorefonts installer had not completed.  I ignored it, because I don't use any Microsoft products, and frankly prefer the Ubuntu fonts.    The pop-up keeps showing up every time I apply an upgrade or fix.  So I decided I would try to correct the problem.    First I dropped to terminal and ran:  sudo apt purge ttf-mscorefonts-installer  That ran without issue.  Then ran sudo apt install ttf-mscorefonts-installer  Now this is where the fun began.  During the install I could not accept the EULA, and had to quit the terminal with only a partial and corrupted install.    Now I can't purge because the file is corrupted, and wants me to reinstall first, but when I try to reinstall I still hang up unable to accept the EULA.  Any advice from the Ubuntu Wizards?

After fresh install 12.04 I && updating apt and system restart, I always get this annoying message after reboot :     Failure to download extra data files      The following packages requested additional data downloads after   package installation, but the data could not be downloaded or could   not be processed.      ttf-mscorefonts-installer      The download will be attempted again later, or you can try the   download again now. Running this command requires an active Internet   connection.   But if I run attempt now, it shows flashing terminal window and like nothing happen. It'll happen again when I restart system.  I found someone have  too, but he haven't replied yet.   I'm a newbie here, please help.


One of the features of the Arcane Archer fighter subclass is Curving Shot:  At 7th level, you learn how to direct an errant arrow toward a new target. When you make an attack roll with a magic arrow and miss, you can use a bonus action to reroll the attack roll against a different target within 60 feet of the original target. [XGtE, pg. 28]  How does this interact with cover? The PHB description of cover says, among other things:  A target can benefit from cover only when an attack or other effect originates on the opposite side of the cover. [PHB, pg. 196]  So what's the origin of a Curving Shot attack?  I see two possibilities:  The origin of the redirected attack is the original, missed target.  The origin remains at the archer.    Related:

One of the features of the Arcane Archer fighter subclass is Curving Shot:  At 7th level, you learn how to direct an errant arrow toward a new target. When you make an attack roll with a magic arrow and miss, you can use a bonus action to reroll the attack roll against a different target within 60 feet of the original target. [XGtE, pg. 28]  How does this interact with range? The Player's Handbook describes range as follows:  The range lists two numbers. The first is the weapon’s normal range in feet, and the second indicates the weapon’s maximum range. When attacking a target beyond normal range, you have disadvantage on the attack roll. You can’t attack a target beyond the weapon’s long range. [PHB, pg. 147]  I see at least four ways this might interact with Curving Shot:  The distance between the old target and new target is added to the shot's original range.  This may extend the range to beyond normal (in which case the new attack role must be made at disadvantage) or beyond maximum (in which case the new target is not valid).  The range of the redirected shot is only the distance between the old target and new target.  The shot has a new point of origin at the old target, so the new range will be between 0 and 60 feet, as limited by Curving Shot.  The range of the redirected shot is the distance between the archer and the new target.  If the new target is farther from the archer than the old one was, the range will be larger; if the new target is closer, the range will be smaller.  The range between the archer and old target is all that matters. As long as the distance from the old target to the new target is within the 60 feet defined in Curving Shot, the initial range between the archer and the old target is all that matters.  The initial attack is rerolled as is.    Related


I have partitioned an external HDD on linux (gpt, ext4) and mounted it under /mnt and would like to use it as a storage device for the whole team, meaning everyone would have all permissions to all files even on other Linux machine (unless one changes the ownership and mode manually). If someone creates a new file on their PC, someone else on another PC would also be able to read and write those files. Running sudo chmod -R 774 /mnt/NewDrive/ does the job but not for new files created after running the command. Am I jeopardizing the security of the machine this external HDD is connected to? What is the safest practice?  Finally, how can I set up such an external HDD that functions just like a shareable flash drive?

I want to format my USB stick to ext4 and just use as I would any other typical non-linux format drive (FAT32, exFAT, NTFS).   That is to say, I want to be able to plug the usb stick into any of my linux machines, and read/write to it without needing to adjust permissions, like doing chmod or chown stuff.  I would prefer to use GUI partition software like GParted, rather than command-line commands, though I welcome any solution!  I'm sure a post like this is duplicate flag heaven for some, but after browsing 6~10 SO and forum posts from google, I didn't find a simple solution to my question. Seemed like everything was about adjusting permissions on a per-user basis. Maybe you just cannot use ext4 drives with the same brainless convenience as NTFS.


I have some basic template programming errors.  I have this code in main.cpp:  #include <string> #include <iostream> #include "arrapp.h" #include <algorithm> #include <vector>  const int max = 1000;  int main() {   int your_mark = 1;   /* 2-es*/   int s[] = {3, 2};   array_appender<int> ia ( s, sizeof( s ) / sizeof( s[ 0 ] ) );   for( int i = 0; i < max - 1; ++i )   {     ia.append( s, sizeof( s ) / sizeof( s[ 0 ] ) );   }    std::string hw[] = { "Hello", "World" };   std::string langs[] = { "C++", "Ada", "Brainfuck" };   std::string x[] = { "Goodbye", "Cruel", "World" };   array_appender<std::string> sa ( hw, sizeof( hw ) / sizeof( hw[ 0 ] ) );   sa.append( langs, sizeof( langs ) / sizeof( langs[ 0 ] ) );   sa.append( x, sizeof( x ) / sizeof( x[ 0 ] ) );    const array_appender<std::string> ha( hw, sizeof( hw ) / sizeof( hw[ 0 ] ) );     if ( max * 2 == ia.size() && 3 == ia.at( max ) && 2 == ia.at( 3 ) &&        &( s[ 0 ] ) == &(ia.at( max / 2 ) ) && 2 == ha.size() && 8 == sa.size() &&        "C++" == sa.at( 2 ) && 7 == sa.at( 5 ).length() && &( ha.at( 0 ) ) == hw )   {     your_mark = ia.at( max + 1 );   }   std::cout << "Your mark is " << your_mark;   std::endl( std::cout ); }   And I have to solve this, by writing "arrapp.h". So I created this:  #ifndef arrapp_H #include <algorithm> #include <list> #include <vector> #include <array>  template <typename T> T const& array_appender (std::vector <T const&> v, T const& size) {    std::vector<T*> vec [size]= {};     for( int idx = 0; idx < size; ++idx)     {         std::cout << "value of v: " << v[idx] << std::endl;         vec.add(v[idx]);     }    return vec; } #endif // arrapp_H   But If I use this i got the error main.cpp|14|error: expected ';' before 'ia'|. So this isn't working. How can I create these template things, to work? Am I  misunderstood, here array_appender don't have work as I think, as I wrote?

This question attempts to collect the few pearls among the dozens of bad C++ books that are published every year. Unlike many other programming languages, which are often picked up on the go from tutorials found on the Internet, few are able to quickly pick up C++ without studying a well-written C++ book. It is way too big and complex for doing this. In fact, it is so big and complex, that there are very many very bad C++ books out there. And we are not talking about bad style, but things like sporting glaringly obvious factual errors and promoting abysmally bad programming styles. Please edit the accepted answer to provide quality books and an approximate skill level — preferably after discussing your addition in . (The regulars might mercilessly undo your work if they disagree with a recommendation.) Add a short blurb/description about each book that you have personally read/benefited from. Feel free to debate quality, headings, etc. Books that meet the criteria will be added to the list.  Books that have reviews by the Association of C and C++ Users (ACCU) have links to the review. *Note: FAQs and other resources can be found in the  and under .


dvd95 was .  Do you know of any alternative as easy to use as that one (or maybe even easier) and that it is native for GTK environments or maybe that can be used via an easy CLI?    k9copy, as suggested below, pulls 126 packages of dependencies, marking it as not a serious alternative. For example, installing a program for Windows through wine will take a lot less space and need less dependencies than k9copy.  This question was marked as a duplicate of . I believe that this is not duplicate because of the comment to  to that question:     dvd95 does not work like dvdshrink;   I personally do not know DVD-Shrink, since I always used dvd95 and I would like to have an alternative to the latter, not to the first.

Is there a linux alternative to the Windows application DVD-Shrink, that can compress a DVD image to a smaller size to fit on a writeable DVD?  In backing up some DVD's the ripped ISO file size is over 7000MB is there an alternative linux software, similar to Windows "DVD Shrink" that can compress this to fit on a writeable DVD which is about 4000MB


My "add comment" button is disabled and I am not able to add comments/give a quick answer to a question, why did this happen, and when will I get the button back?

Across the Stack Exchange network you may leave comments on a question or answer.  How do comments work? What are comments for, and when shouldn't I comment? Who can post comments? Who can edit comments? How can I format and link in comments? My comment doesn't contain some of the text I typed in it; why? My comment appears to be long enough, but I can't post it because it's too short; why? Who can delete comments? When should comments be deleted? Why can't I comment on specific posts even if I have enough reputation to comment? When can comments be undeleted? What are automatic comments? How can I link to comments? Anything else I should know about comments?  Also see the FAQ articles on  and .


Well-known game journalists TotalBiscuit and Jim Sterling use [the number of frames per second] fps instead of 30FPS or 30 FPS, without an intervening space between the units and the following units (like 30fps or 60fps). Example One   PC users will be delighted to know it’s [the game] locked at 30fps on all platforms.  Example Two   24fps lock 30fps lock    In my opinion 30 FPS (with space) is correct. Who is right?

I remember reading somewhere that if a unit is abbreviated as one character, there must not be a space between the number and the unit (e.g., 5m, 26K). If the unit is abbreviated as two or more Characters, there must be a space between the number and the unit (e.g., "10 km", "USD 5").   Can you please help me find the source again? Is this recommendation correct?


I'm trying to make a stacked bar chart with two bars next to each other with different colors. I've based my code on discarding \addplot commands similar to , but even though I'm discarding an \addplot it seems to remember the height of the previous bar (due to stacking presumably). I want all bars to start at y=0.  \documentclass{standalone} \usepackage{filecontents}  \usepackage{pgfplots} \usepackage{pgfplotstable}  \pgfplotsset{     discard if/.style 2 args={         x filter/.code={             \edef\tempa{\thisrow{#1}}             \edef\tempb{#2}             \ifx\tempa\tempb                 \def\pgfmathresult{inf}             \fi         }     },     discard if not/.style 2 args={         x filter/.code={             \edef\tempa{\thisrow{#1}}             \edef\tempb{#2}             \ifx\tempa\tempb             \else                 \def\pgfmathresult{inf}             \fi         }     } }  \begin{document}  \begin{filecontents}{data.csv} X   Alpha   Name    Normal  Spike   Min     Max 1   5       CR      2.42    3.19    0.92    0.98 2   5       LR      2.48    0.80    0.59    0.47 4   10      CR      2.03    3.30    1.76    2.21 5   10      LR      2.10    0.92    0.53    0.62 7   15      CR      2.03    2.88    1.60    1.28 8   15      LR      2.05    1.12    0.68    0.69 \end{filecontents}  \pgfplotstablegetrowsof{data.csv} \edef\numberofrows{\pgfplotsretval}  \begin{tikzpicture} \begin{axis}[     width=10cm,height=6cm,     ybar stacked,     xtick={1,2,4,5,7,8},     xticklabels from table={data.csv}{X}, ]  \addplot [draw,fill=orange,discard if={Name}{LR}] table [x=X, y=Normal] {data.csv}; \addplot [draw,fill=orange!20,discard if={Name}{LR}] table [x=X, y=Spike] {data.csv};  \addplot [draw,fill=green,discard if={Name}{CR}] table [x=X, y=Normal] {data.csv}; \addplot [draw,fill=green!20,discard if={Name}{CR}] table [x=X, y=Spike] {data.csv};  \end{axis} \end{tikzpicture}  \end{document}

How can I get multiple stacked plots (ybar stacked, stack plots=y) in one diagram, such that there are multiple stacked bars for the same x-coordinate, each slightly shifted? Is there a way to reset pgfplot's zero levels after an \addplot command, such that the next \addplot[xhshift=...] doesn't add something to the current stack, but rather starts a fresh stack?  FWIW, overlaying two plots with scale only axis won't help; I need this to work with groupplot


Last night I installed KDE. But then however my Desktop manager changed into KDM. How can I go back to my default Desktop manager lightdm??

I have LightDM installed and can start it with sudo start lightdm. But at boot, GDM is still the default. How can change this so LightDM is loaded automatically at boot instead of GDM?


Trying to identify book about woman who bioengineers giant telepathic wolves that have some kind of alien DNA spliced into them. The woman/scientist also has some wolf DNA spliced into her giving her a wolf's sense of smell. Her colleagues have more advanced adaptations enabling them to full body morph into wolves, the three scientists and three wolves make up a pack and they are on another world performing some kind of test.  The story flashes back to memories of how the lead scientist got to where she is today, remembering her time working for another alien race that called other races "vermin" in their own language and a friend she had of that alien race called her by a nickname that meant "acceptable vermin".  There is also a section of the story following a high ranking male in the political structure of a race of lizard-men. This race starts out very stupid bit individuals gain intelligence and comprehension with age as they loose their blood-lust. A warring race with no real culture, the oldest males rule the geopolitics of the planet with some interference by a bug like race. The females are as witless as cows. But this high-ranking male, while performing a ceremony to claim several new sons to raise from a clutch, decides to dispatch the unworthy offspring himself as an afterthought, and walks in on a technician of some sort lobotomizing the female hatchlings.  Turns out the females are the smart ones and the bug race put this custom in effect to control the lizard men. It hints at a greater story there but never quite circles back, going back to the woman and the wolves and some threat of an ancient alien shapeshifter, i believe called Zaag or Zaar or something like that. Turns out the D.N.A. spliced into the wolves came from that race of aliens and are evil, the charismatic wolf alpha who has scent glands in the roof of his mouth used for "speech" via smell, is this zaarg alien character, perhaps somehow reincarnated or reconstituted from the bioengineered cells?  I cant remember much else. And all of this is through the scientist woman's memories as she waits outside a door to speak to someone, and stops to wash her face at a basin to wash away tears and calm herself. I thought the book was called "Companions" but haven't been able to find it in years. I read it probably 10 years ago from my local library. They no longer have it or know what book it was. I want to reread it as an adult and see if its a good as i remember. It seemed like it would've been the first book in a series. Please help.

I'm looking for the name of a science-fiction novel/series, which I read sometime between 2001-2005. The only things I can definitely remember:   There are "pleasure bots" (there's a name for them in the book, but I forget), actually very life-like, that are stored in some sort of case when not in use. (Sort of like the ivory dittos from "Kiln People", but these are more-or-less autonomous, if a bit empty-headed.) No one is really sure where these androids came from, but at some point in the book (or later in the series) it is revealed that they were created by a woman scientist-type (who might have been the protagonist in an earlier book in the series) for the purpose of population control, and to reduce violence against women. I think the woman scientist is near-immortal, or can time-travel; unless I'm getting different works mixed up, this pleasure-bot scheme is one of several interventions she performs across centuries, if not millenia.


I need a script that can SSH to multiple servers and execute a find command to check when was the last time a file was created.

There is a list of IP addresses in a .txt file, ex.:  1.1.1.1 2.2.2.2 3.3.3.3   Behind every IP address there is a server, and on every server there is an sshd running on port 22. Not every server is in the known_hosts list (on my PC, Ubuntu 10.04 LTS/bash).  How can I run commands on these servers, and collect the output?  Ideally, I'd like to run the commands in parallel on all the servers.  I'll be using public key authentication on all the servers.  Here are some potential pitfalls:   The ssh prompts me to put the given servers ssh key to my known_hosts file. The given commands might return a nonzero exit code, indicating that the output is potentially invalid. I need to recognize that. A connection might fail to be established to a given server, for example because of a network error. There should be a timeout, in case the command runs for longer than expected or the server goes down while running the command.   The servers are AIX/ksh (but I think that doesn't really matter.


Is there a simpler expression for the following sum? $(n\in\mathbb{N})$ $$S_n =\binom{n}{0}\binom{n}{1} + \binom{n}{1}\binom{n}{2} + \dots + \binom{n}{n-1}\binom{n}{n}$$ It seems like $S_n = \binom{2n}{n-1}$, however I have no clue as to how I can prove that relation. I also tried re-writing the sum as $$S_n = \binom{n}{0}\binom{n}{n-1} + \binom{n}{1}\binom{n}{n-2} + \dots + \binom{n}{n-1}\binom{n}{0} = \sum^{n-1}_{j=0}\binom{n}{j}\binom{n}{n-j-1}$$ Which resembles a special case of . Is there a connection between the two?

$$\binom{n}{0}\binom{n}{1}+\binom{n}{1}\binom{n}{2}+...+\binom{n}{n-1}\binom{n}{n}$$   All I could think of so far is to turn this expression into a sum. But that does not necessarily simplify the expression. Please, I need your help.


I have been studying for my Unix exam and I often saw exclamation mark variable - $! If I write echo $! on my Mac shell tells me something like "You have mail in…"  Is purpose of this to store whether I do or do not have any mails or is there something else?  EDIT: Funny coincidence happened. Exactly when I wrote echo $! my Shell also notified me that I have some mail. So that's why I wrote that mail part.

If I'm assigning a variable with  temp=$!   what would it be its value?


A set consists of intervals in $\mathbb{R}$. They have no intersection, their starting point and end point can be any numbers(not limited to rational number), and the union all intervals should cover all real numbers. For example, the first interval is $[0,1)$ then the next interval can be $[1,6)$, but not $[0.5,2)$. How many such intervals? Is it countable infinity?

According this problem/solution set from an MIT class (http://ocw.mit.edu/courses/mathematics/18-100c-analysis-i-spring-2006/exams/exam1_sol.pdf), the assertion:  "Every collection of disjoint intervals in R is countable."  is True, because "every interval contains a rational number", and the rationals are countable.  It seems to me this should be False, with possible counterexample:  { [x,x] | x is an element of R}  ie the set of all singelton intervals on R. Why isn't this a valid counterexample?


I have two software centers in Ubuntu, but I am sure there should be one:    And Moreover both have the source "ubuntu focal-main". Can anyone help?

I recently fresh reinstalled Xubuntu 20.04lts on two of my pcs. Suddenly after a few weeks, i discovered a couple of differences between these pcs, were i did not alter anything. It seems that the Software store (gnome-software) looks like being different versions compared between both systems. one has a Source tab on the top right next to minimize, the other lacks that and has a gear for options there. (containing nothing special only software and updates, and two options for updating software) This source tab gives access to flatpak software, and a little extra sources. Also i cannot find this tab anywhere on the other pc in the gnome-software application. The other point is, that on this pc, which has extra sources for software like flatpak, the snap-store seems to be replaced for gnome-software. What means, that when i click the snap-store icon, it starts gnome-software. also i tried running it by terminal with snap-store, but the same result. i dont know what happened here. first of all, how can i get these flatpak resources also, with that source tab on the other pc (in gnome-software), and how do i ¨restore¨ the snap-store to working state. the other pc by the way does have a working snap-store. i have compared the ppas of both, and there are no differences, and nothing has been added.


is there an explicit definition of the following sequence? $$s(n)=\sum_{i=0}^n \frac1{i!}$$ Sincerely

Is there a closed form solution for the following series? (Without Using Gamma Function): $$ S=\sum _{i=1}^{n-1} \frac{1}{(i+1)!} $$


I'm getting permission denied when I try to access my old 10.04 partition. I'm trying to get into the home folder so that I can back up the data before I do a fresh install of 12.04.  I know the password but not how to get the proper permissions so that I can move stuff via the GUI.  How can I do this?

For some reason I can't boot my system. I get an error akin to Operating System Not Found.   I tried bootrepair, and that didn't work. So then I decided I would just save my personal files, wipe everything, and reinstall.   But in the live session, when I go to the /home directory, my username folder isn't there, instead it goes to the Live CD's desktop and other directories. Is there some other error occurring? Is there a way to recover the files?


Recently I started learning to use keyboard shortcuts almost for everything I'm doing on the laptop (os win7) but soon enough after I started, I bumped into the problem of being unable to highlight (select) simple text in the Stack Exchange sites (where I stay almost all the time). I did some research and I couldn't find any solution to my problem. Have I missed an already answered question that is the same like mine or if not what solution can you suggest in order to achieve the results I want without touching mouse or touchpad or any cursor moving device?

Recently I started learning to use keyboard shortcuts almost for everything I'm doing on the laptop, but soon enough after I started, I bumped into the problem of being unable to highlight (select) simple text in Skype chats.  I did some research and I couldn't find any solution to my problem. Have I missed an already answered question that is the same like mine or if not what solution can you suggest in order to achieve the results I want without touching mouse or touchpad or any cursor moving device?


I tried to filter for questions that have not been deleted.    However, the top result shows  Post Link                                                           deletiondate closeddate           ------------------------------------------------------------------- ------------ -------------------  Should I learn "Legacy Spring", or just jump to Spring Boot         null         null                   It shows null for deletiondate, yet .     deleted by LightCC 13 hours ago   So how do I only display questions that are not deleted?  select top 1000 p.id as [Post Link], p.deletiondate, p.closeddate from posts p where p.answercount = 0 order by p.creationdate desc

There was an update around the 17th or 18th. Now, I see that all of the sites have been updated as of the 25th. I know that there was a time when a weekly or every-two-week update cycle was planned, but I couldn't find any confirmation of this having been implemented. The  still says monthly, but there had been a delay of a few months at one point, so I'm not entirely sure that the FAQ is trustworthy on all points. Every other post that I've found about the Data Explorer is at least a few months old, and this appears to be a recent change.


I'm not familiar with algorithm complexity so I'm asking here. I need help determining degital signature complexity, I did some research and all I found is complexity for the D.S.A only: 𝑂(𝐷𝑆𝐴 𝑆𝑖𝑔𝑛𝑎𝑡𝑢𝑟𝑒) =𝑂(2 𝑙𝑜𝑔𝑛). 𝑂(𝐷𝑆𝐴 Verification) = 𝑂(3𝑙𝑜𝑔 𝑛). I'm using RSA Signature and SHA-2 hush function.

What's the computational complexity or RSA? One can assume it's O(prime length^2) it you consider multiplication by column, but speed tests slightly differ on slow operations with private key and differ a lot on public key. Why?  > openssl speed rsa1024 rsa2048 rsa4096                    sign    verify    sign/s verify/s rsa 1024 bits 0.002544s 0.000124s    393.1   8049.2 rsa 2048 bits 0.017023s 0.000467s     58.7   2140.7 rsa 4096 bits 0.121189s 0.001824s      8.3    548.2


ID      domain 1      yahoo.com 2      yahoo.com 3      gmail.com 4      gmail.com   Let's say I have a statement like this  SELECT ID, domain, COUNT(*) as total FROM table WHERE blah = 123 GROUP BY domain   Is it possible to get each individual ID number, but while in a COUNT? I need to count the records but I also need the individual record ID numbers as well. I am pretty sure this is impossible but ultimately I need the totals and ID's  domain       total yahoo.com     2 gmail.com     2   but also have the ID's (1,2 for yahoo.com) and (3,4 for gmail.com)

Using MySQL, I can do something like:  SELECT hobbies FROM peoples_hobbies WHERE person_id = 5;   My Output:  shopping fishing coding   but instead I just want 1 row, 1 col:  Expected Output:  shopping, fishing, coding   The reason is that I'm selecting multiple values from multiple tables, and after all the joins I've got a lot more rows than I'd like.  I've looked for a function on  and it doesn't look like the CONCAT or CONCAT_WS functions accept result sets.  So does anyone here know how to do this?


I have the following code:  String date_p = request.getParameter("myText");     DateFormat sdf = new SimpleDateFormat("dd-MMM-yyyy");     java.util.Date frmDate = sdf.parse(date_p);   I get the error as:  type Exception report  message An exception occurred processing JSP page /demo3.jsp at line 22  description The server encountered an internal error that prevented it from fulfilling this request.  exception  org.apache.jasper.JasperException: An exception occurred processing JSP page /demo3.jsp at line 22  19:  20:     String date_p = request.getParameter("myText"); 21:     DateFormat sdf = new SimpleDateFormat("dd-MMM-yyyy"); 22:     java.util.Date frmDate = sdf.parse(date_p);  Stacktrace:     org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:575)     org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:477)     org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:395)     org.apache.jasper.servlet.JspServlet.service(JspServlet.java:339)     javax.servlet.http.HttpServlet.service(HttpServlet.java:731)     org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)    root cause  java.lang.NullPointerException     java.text.SimpleDateFormat.parse(Unknown Source)     java.text.DateFormat.parse(Unknown Source)     org.apache.jsp.demo3_jsp._jspService(demo3_jsp.java:106)     org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)     javax.servlet.http.HttpServlet.service(HttpServlet.java:731)     org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:439)     org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:395)     org.apache.jasper.servlet.JspServlet.service(JspServlet.java:339)     javax.servlet.http.HttpServlet.service(HttpServlet.java:731)     org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)   Why is the parse function not working? I have imported these packages as well - "java.sql., java.util., java.text.*"

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?


my screen is frozen on the slide to power off screen and it won't let me get out of it. I've tried holding down the home button and the lock button for a long time and it hasn't worked. I've also tried using siri and haven't gotten anywhere. I plugged in my phone as well and that didn't do anything either. I have an iPhone 7

I understand that when I press and release the power button on the top of my iPhone or iPad, it stays on but turns off the screen.  Whereas if I press and hold the power button, a "slide to turn off" control appears on the screen.  Sliding this, as I was told, does turn the unit off, but it does so by suspending the RAM to disk (flash memory, actually.) So, when turning on the iPhone or iPad, it isn't so much rebooting the OS as it is resuming it from flash storage.  How to force the OS to completely reboot on these devices?


When I log in remotely to a Windows box (using Windows Remote Desktop), I can see that the Computer Management applet shows 6 "Intel Xeon CPU" entries under "Processors", as shown below.    (Based on ramhound's comment this amount of "Processors" is because of HT is not enabled.)  The Lenovo X1 Carbon laptop that I am using, on another hand, has the Intel's Core i5 CPU. Considering that this is a rather lightweight laptop, I would assume that this is just one CPU with 4 cores. The cores are listed in Computer Management applet as shown below.    I would like to know if the remote computer has multiple processors or just 1 processor with multiple cores. It is not close by so I am not able to get to it and open up the case.  Thus the question I wanted to ask is: How can it be determined if a Windows PC has multiple processors or just 1 processor with multiple cores, without opening the computer case?

I got me a nice new laptop and I want to know a bit more about the hardware.  How can I see how many CPUs my computer has in Windows 7?  (Note: Clicking on Start → right clicking on Computer → selecting properties shows me the processor type, but it does not say anything about the core count.)


I'd like to install Ethernet in my Ubuntu, but the error message still be occurred like this:  tcpdump: eth0: No such device exists (SIOCGIFHWADDR: No such device)    root@ubuntu:~# tcpdump -D 1.ens33 [Up, Running] 2.any (Pseudo-device that captures on all interfaces) [Up, Running] 3.lo [Up, Running, Loopback] 4.bluetooth0 (Bluetooth adapter number 0) 5.nflog (Linux netfilter log (NFLOG) interface) 6.nfqueue (Linux netfilter queue (NFQUEUE) interface) 7.usbmon1 (USB bus number 1) 8.usbmon2 (USB bus number 2)   I have only these things in my Ubuntu.

We have dozens of virtual machines in several data centers around the world. When upgrading an Ubuntu VM from 14 to 16 (as a step toward upgrading them to Ubuntu 18), the network interface names change. I am aware of this, and I know why they change, so that is not my question. My question is where does the number (the 33 in ens33, the 192 in ens192, etc.) come from? I have read many StackExchange questions and answers about what to do to get the server working: that is not the problem. What I want to know is how to predict what the ens### will be before the server is upgraded to Ubuntu 16. I have looked at lshw and lspci, and I can't see any reason why these numbers are chosen.  Please: where does the 192 (or 33, or anything else) come from?


I just learning Parse but I have a problem. So I am trying to get information from AWS, the username and the score,unfortunatly I can't do it,the app crashes every time and return null. This is the username and their id's:  Crash errors(Errors lines marked in my code):  My code: package com.example.parseserverstarterproject;  import androidx.appcompat.app.AppCompatActivity;  import android.os.Bundle; import android.util.Log;  import com.parse.GetCallback; import com.parse.Parse; import com.parse.ParseAnalytics; import com.parse.ParseException; import com.parse.ParseObject; import com.parse.ParseQuery; import com.parse.SaveCallback;  public class MainActivity extends AppCompatActivity {       @Override     protected void onCreate(Bundle savedInstanceState) {         super.onCreate(savedInstanceState);         setContentView(R.layout.activity_main);          ParseQuery<ParseObject> parseQuery = ParseQuery.getQuery("Score");          parseQuery.getInBackground("AQ1BdZT7vV", new GetCallback<ParseObject>() { // LINE 47             @Override             public void done(ParseObject object, ParseException e) {                 if (e == null && object != null){                Log.e("username",object.getString("username")); //LINE 52                Log.e("score", String.valueOf(object.getInt("score")));              }             }         });          ParseAnalytics.trackAppOpenedInBackground(getIntent());      } }


I am at my wit’s end with File Server clustering under Hyper-V. I am hoping that someone might be able to help me figure out this Gordian Knot of a technology that seems to have dead ends (like forcing cluster VMs to use iSCSI drives where normally-attached VHDX drives could suffice) where logic and reason would normally provide a logical solution.  My hardware:  I will be running three servers (in the end), but right now everything is taking place on one server. One of the secondary servers will exist purely as a witness/quorum, and another slightly more powerful one will be acting as an emergency backup (with additional storage, just not redundant) to hold the secondary AD VM and the other halves of a set of clustered VMs: the SQL VM and the file system VM. Please note, these each are the depreciated nodes of a cluster, the main nodes will be on the most powerful first machine.  My heavy lifter is a machine that also contains all of the truly redundant storage on the network. If this gives anyone the heebie-geebies, too bad. It has a 6TB (usable) RAID-10 array, and will (in the end) hold the primary nodes of both aforementioned clusters, but is right now holding all VMs. This is, right now: DC01, DC02, SQL01, SQL02, FS01 & FS02. Eventually, I will be adding additional VMs to handle Exchange, Sharepoint and Lync, but only to this main server (the secondary server won't be able to handle more than three or four VMs, so why burden it? The AD, SQL & FS VMs are the most critical for the business).  If anyone is now saying, “wait, what about a SAN or a NAS for the file servers?”, well too bad. What exists on the main machine is what I have to deal with.  I followed , but I seem to be unable to get things to work. In order to make the file server truly redundant, I cannot trust any one machine to hold the only data store on the network. Therefore, I have created a set of iSCSI drives on the VM-host of the main machine, and attached one to each file server VM. The end result is that I want my FS01 to sit on the heavy lifter, along with its iSCSI “drive”, and FS02 will sit on the secondary machine with its own iSCSI “drive” there as well. That is, neither iSCSI drive will end up sitting on the same machine as the other. As such, the clustered FS will utterly duplicate the contents of the iSCSI drives between each other, so that if one physical machine (or the FS VM) goes toes-up, the other has got a full copy of the data on its own iSCSI drive.  My problem occurs when I try to apply the file server role within the failover cluster manager. Actually, it is even before that -- it occurs when adding the disks. Since I have added each disk preferentially to a specific VM (by limiting the initiator by DNS hostname, and by adding two-way CHAP authentication), this forces each VM to be in control of its own iSCSI disk. However, when I try to add the disks to the Disks section of Storage within Failover Cluster Manager, the entire process fails for a random disk of the pair. That is, one will get online, but the other will remain offline because it does not have the correct “owner node”. I mean, really -- WTF? Of course it doesn’t have the right owner node, both drives are showing the same node name!! I cannot seem to have one drive show up with one node name as owner, and the other drive show up with the other node name as owner. And because both drives are not “online”, I cannot create a pool to apply to a cluster role. Talk about getting stuck between a rock and a hard place!  I’ve got more to add, but my work is closing for the day and I have to wrap things up. I will try to add more tomorrow morning when I get in.  My main objective is to have a file server VM on each machine, the storage on each machine, but a transparent failover in case one physical machine fails. Essentially, a failover FS that doesn’t care which machine fails -- the storage contents are replicated equally on each machine. Am I even heading in the right direction?

I have been using Microsoft’s Hyper-V technology for a little while now, but I am just now dipping my toe into clustering.  In particular, I am trying to implement a fault-tolerant SQL DB. This involves setting up two VMs, clustering them via Failover Cluster, and then installing SQL Server in some fashion. I have two physical machines - one high-end and rather beefy “heavy lifter” to contain the majority of the VMs, and another “backup” (a repurposed desktop) to hold the essential “secondary” (or failover) AD-DC, SQL and FS VMs.  The main reason why I find the failover cluster at the VM level so attractive is that it presents a single IP and DNS entry to the network as a whole - if one machine (physical or virtual) goes down, you might loose some ping and the connections get reset, but the network applications (Microsoft RMS connection to backend SQL) can still connect to a viable DB without having to mess around with the settings at all.  My first question is in terms of SQL Server itself. If I have a cluster between two VMs, does it make more sense to install the SQL Server in Failover Cluster configuration or should I simply install it in a stand-alone config and mirror the DBs? For example,  suggests just mirroring the DBs, but do I just mirror standalone DBs on standalone VMs, or can I get the network and failover benefits of clustered VMs while still utilizing (on each clustered VM) standalone DBs that have been mirrored between each other?  As well, I have come across a lot of documentation about SQL clustering, but most assume a number (#>2) of physical machines to hold not only the actual SQL VMs but also the Quorum and Witness stores. I will not be able to muster more than two physical machines. As such, I will have to be satisfied with a VM cluster that does not exceed two VMs (one for each physical machine).  Another issue involves MSDTC - the Distributed Transaction Coordinator. When attempting to install the SQL Failover Cluster (I never completed it for this reason) it threw a hissy fit because MSDTC had not been clustered. Search as I might, I have not yet found a way to do so under Windows Server 2012 R2. I have found , but these instructions don’t align with 2012 R2 (at least, not in a way that allows me to successfully cluster MSDTC). Plus,  that I have found for SQL Server Failover Cluster installation suggest that a third “network device” - shared network storage (a SAN) - is required for the DB itself (and other functionality). I do not have this, and won’t be getting this. Most of my storage exists on the “heavy lifter” that was designed for all of the “primary” VMs. If that physical machine goes down, so does the storage. The secondary server does have enough resources for an AD-DC Server, an SQL server and a File Server, so it will handle the “secondary” failover versions of those VMs (clustered or not).  My final question involves file servers. If I cluster file servers between two VMs (one on my “heavy lifter” and another on my “backup”, how do I mirror the data between them? Clustering VMs only provides a single point of access on the network for a resource, it doesn’t exactly replicate data between the two - that is left to the services that serve up that data. I am unsure how I can ensure that file server data between two clustered file server VMs can be properly mirrored. Remember, I only have two devices to be used here - my primary machine and a backup secondary. There is no chance of me obtaining a SAN or any other type of network attached storage. What exists on the machines must act as the storage.  Thanks in advance for any suggestions.


When a question is closed and the reason is not unanimous (or if a mod steps in), the close text will list the names of those involved in the closure along with the ultimate close reason calculated by the system, for example here in the history of :    This can result in the OP and others assuming particular votes were cast, eg in the example above, the OP assumed Craig Ringer had cast an "off-topic" vote, but in reality :     @JohnMerlino I just voted it for migration. It's seriously annoying the way Stack Overflow puts my name by it when it's closed when I didn't suggest that.... oh, it was closed by bluefeet (moderator). I've asked for migration + reopen. Sorry for the confusion...   (my emphasis)   Wouldn't it be better to anonymize the users who voted to close with a different reason than the eventually accepted one? eg:     Post Closed as "off-topic" by one user and bluefeet♦   or alternatively just:     Post Closed as "off-topic" by bluefeet♦.   In the latter case, if there is not a mod closure, experienced users would know that if there are less than five users shown it means a split decision. The post history could contain a fuller record of the vote.

Even though a question may be closed by receiving 5 close votes, the votes do not necessarily need to agree.  I think this is a good behavior, but  (which it was) and found the question was closed as "not a real question".  This is unfortunate, while I'm happy to display my username and acknowledge that I voted to close, I'd like some additional transparency.  That is, if it was a 4-1 vote for "not a real question" vs "exact duplicate" I'd be interested in seeing that level of information.  The point is to be transparent about why the question was closed, and though 5 users may agree the question needs to be closed they may not agree why.  It's important to recognize all the reasons for closure, not just the majority reason.  I'd suggest displaying this information as something like:     closed on Jun 21 at 4:26 as:         not a real question by foo, bar, baz   exact duplicate by alice, bob      Once a question has been closed I'd argue it's more important to understand the rationale than it is to worry about an extra 2 lines of text. If the votes are 2,1,1,1 perhaps keep just 2 bullets, the first showing the majority vote, the second saying "for other reasons" as a summary of the change.  The point is to aggregate the summary by reason.


!st ed: The Summon Monster and Summon Nature's ally spells all have a casting time of 1 round.  My regular group have always taken that to mean that the summoned creature begins to act in the following round.  My new group (I'm GM for the first time) is claiming that it should appear and start to act in the round in which the spell is cast.  Who is right?  Does it make any difference if the caster is actually a Preservationist Alchemist invoking Bottled Ally?

Each spell has it's own casting time, e.g.  takes 1 full round and  takes a swift action.   On the other hand,      Drinking a potion or using an oil is a standard action    as      In many ways, they behave like spells in potion form, and as such their effects can be dispelled by effects like dispel magic using the alchemist's level as the caster level. Unlike potions, though, extracts can have powerful effects and duplicate spells that a potion normally could not.   So how long does consuming an extract take? I'm inclined to believe that it takes just as long as the spell does to cast (e.g. a full round to Enlarge Person, only a swift for Burst of Speed) but I'd love to know if this is ever clarified in the rules or a FAQ that I've missed.


Europa is an example of a satellite which is heated by tidal forces. The orbit is constant, so how is energy conserved on Europa?

Jupiters moon Io is heated through the gravitational pull of Jupiter, but when Io is heated because of this, where does that energy come from? How does conservation of energy work for this effect, where is energy "lost"?


TeXLive installs a lot of fonts. How can I know which of them support Cyrillic letters?

I'm trying to figure out what fonts are compatible with T2A encoding - seems like there's no such a list known to Google.  I've identified that iwona and computer roman (default) are supported. However, attempts to use other fonts with either \usepackage{lmodern} or \renewcommand*\rmdefault{phv} in preamble result in a warning      Font shape "T2A/lmr/m/n" undefined(Font) using "T2A/cmr/m/n" instead.   \documentclass[10pt,a5paper,draft]{book} \usepackage[T2A]{fontenc} \usepackage[utf8x]{inputenc} \usepackage[russian, english]{babel} \usepackage{iwona} \begin{document} Some meaningful text.  Какой-то осмысленный текст. \end{document}   Fonts I've tried so far are: times new roman, garamond, helvetica, palatino.  Maybe I'm missing something, so I'd be happy to be pushed in the right direction.


I am trying to create an easy-to-use interface for array indexing in C++. Unfortunately, I just cannot get my code working. And I think the problem is regrading to C++ does not allow me to cast a base class back to the derived class. However, I am not sure why that happens. Please help me with that.  Here is the code.  #include <iostream> #include <vector>  enum index_type {     single_value,     sequence, };   class idx { protected:     index_type t; public:     idx(index_type _t);     virtual void print_out(); };  class single_idx:public idx { private:     int sidx; public:     single_idx(int _sidx);     void print_out(); };   class multiple_idx:public idx { private:     std::vector<int> midx; public:     multiple_idx(std::vector<int> _midx);     void print_out(); };  idx::idx(index_type _t):t(_t){     switch (t) {         case (single_value):{         std::cout << "single_value\n";         break;         }          case (sequence):{         std::cout << "multiple_value\n";         break;         }     } }  single_idx::single_idx(int _sidx):sidx(_sidx), idx(single_value){}  multiple_idx::multiple_idx(std::vector<int> _midx):midx(_midx), idx(sequence){}  void idx::print_out() {     std::cout << "lalala\n";     switch (t) {         case (single_value):{         std::cout << "casting to single\n";         dynamic_cast<single_idx*>(this)->print_out();  // ERROR happens here!!!         break;         }          case (sequence):{         std::cout << "casting to multiple\n";         dynamic_cast<multiple_idx*>(this)->print_out();         break;         }     } }  void single_idx::print_out() {     std::cout << "single value: ";     std::cout << sidx << "\n"; }  void multiple_idx::print_out() {     std::cout << "multiple value: ";     for (int i : midx) {         std::cout << i << " ";     }     std::cout << "\n"; }  void f(std::initializer_list<idx> a) {     for (idx t : a) {         t.print_out();     } }  int main() {     f({single_idx(1), single_idx(2)}); }

Someone mentioned it in the IRC as the slicing problem.


I sadly cannot remember much about it except that the magic system was based on a spectrum of color.  There were two main characters (one male, one female), and the second book started with them offering a 'blood sacrifice' to bind storm spirits to them on a hill.

Here's what I remember:   The main character's female (99% sure) There is one part where she has to cross a big tundra and she has to kill a big ice creature The kids in the story go to a school-like place where they train for something. I'm pretty sure they earn gems or runes or something like that There's one part where the main character has to play a piece of music perfectly to earn her gem/rune thing It's definitely a series; young-adult (I read them in middle school)   Thanks!


Are the two following equivalent under ZF :   Axiom of Choice/Zorn's Lemma Given any two sets A, B, there exists an injection from A to B or there exists an injection from B to A   I could prove that (1) implies (2) and I wonder if they are actually equivalent  but I couldn't prove it. I read somewhere that (2) cannot be proven with only ZF, that's why the equivalence seems plausible to me.   Thank you :)

It is well-known (forgive the pun) that the axiom of choice (which states that the product of every non-empty family of non-empty sets is non-empty) implies that the proper class of all cardinal numbers is well-ordered, at least in the presence of the ZF axioms.  Does the converse hold? If not, is the statement that the proper class of all cardinal numbers is well-ordered consistent with axioms like determinacy, which, while interesting, contradict full-blown choice?


$$\sum_{n=1}^{\infty} \frac{\cos n}{n}$$ I know that this series converges (from Dirichlet test) but I can't figure if it converges absolutely or not, obviously ratio and root test won't work, limit comparison test seems to fail as well.

I know that the series $\sum_{k=1}^\infty \frac{\sin k}{k}$ converges (to $\frac{\pi - 1}{2}$), though by crazy stuff with Dirichlet Kernels or by reverse-engineering $\frac{\pi - x}{2} = \sum \frac{\sin (kx)}{k}$ using Fourier Series.  My question instead: Is $\sum_{k=1}^\infty \frac{\sin k}{k}$ absolutely convergent?  My gut instinct is no: It behaves not-much-better than $\sum \frac1k$, but that's certainly not a rigorous proof.


I'm currently based in Shanghai, China. I have recently updated my system to iOS 9.2, and after this, my SE app on my iPhone doesn't seem to work well.   The problem is, when my cellphone is connected to a wifi whose condition is not very well, Stack Exchange will almost always crash on startup, stuck in the following stage for several seconds then flashing back to main screen:    By "whose condition is not so well" I mean a wifi that is slow when connecting to foreign websites. (Due to some reasons, many wifi connections in Shanghai are in such a condition, sigh) Even when the wifi connection is so good that the app won't crash, it will still take a much longer time to open it. (Before iOS 9.2, it takes about 2 or 3 sec for the screen to stay in the stage shown in the image above, but now it takes about like 7 or 8, which is really an awfully long time.)  Nonetheless, when I turn my wifi off and connect my phone to 3G cellular network, or even when I simply disconnect my phone from Internet (like turn on airplane mode), the app won't crash and will function just as well as before iOS 9.2. (Of course when on the airplane mode I can't refresh to fetch new info but at least the app doesn't crash!) So now every time I want to browse SE I have to switch to cellular network...  I tried deleting and redownloading and reinstalling the app, but the situation doesn't get any better.   I'm sorry I don't quite know how to get the error log on my iPhone, but if you need any more specific information about this problem I can provide that for you on request.   Thanks in advance.

I've recently noticed a bug on the Stack Exchange IOS app. When I open the Stack Exchange app on weak wifi, it hangs on the blue load screen as it launches and either crashes the app or the entire phone lags and didn't respond for about a minute.  I'm running iOS 8.4.1, I have the most up to date version of the app, and by 'weak' wifi I mean two out of four bars of strength.


I have a list and I a trying to concatenate 2 items in the list using .join().   Sample data:  l = ['a', 'b', 'c', 'd'] str = ' '.join(l[1:2]) print(str)   The output prints only b but I am expecting to print b c. someone point me what is wrong here

I need a good explanation (references are a plus) on Python's slice notation.   To me, this notation needs a bit of picking up.   It looks extremely powerful, but I haven't quite got my head around it.


I have created multiple models using the Processing Modeler in QGIS 2.18.15. However, I could not open these .model files in the user interface for the Graphical/Processing Modeler in QGIS 3.2.1, which seems to only accept .model3 or .MODEL3 files. Also, there is an option to save the (.model) file as a Python (.py) file in QGIS 2.18.15.  Is there a way that I can make either the (.model) or (.py) files from QGIS 2.18.15 compatible for QGIS 3.2.1 Graphical/Processing modeler? Since the alternative to that would be to re-create the Processing Modeler manually from scratch.

Is it somehow possible to convert a QGIS 2.x processing model (*.model) to a *.model3 so i can run them in QGIS 3.0 without having to redo mine from scratch?


Design is simple but dont know what causing the error.   <?xml version="1.0" encoding="utf-8"?>     <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"         xmlns:app="http://schemas.android.com/apk/res-auto"         xmlns:tools="http://schemas.android.com/tools"         android:orientation="vertical"         android:layout_width="match_parent"         android:layout_height="match_parent">              <LinearLayout                 android:layout_width="match_parent"                 android:layout_height="wrap_content"                 android:orientation="vertical"                 android:layout_gravity="top">                  <include                     android:id="@+id/toolbar"                     layout="@layout/toolbar" />             </LinearLayout>              <include layout="@layout/activity_main"/>            <fragment             android:id="@+id/fragmented1"             android:layout_width="match_parent"             android:layout_height="match_parent"             android:layout_gravity="top"             app:layout="@layout/search_box"             tools:layout="@layout/search_box" />      </LinearLayout>      public class MainActivity extends AppCompatActivity {          RelativeLayout search;         TextView textView;         ImageView close_btn,filter_cars;         Intent intent;          @Override         protected void onCreate(Bundle savedInstanceState) {             super.onCreate(savedInstanceState);             setContentView(R.layout.main);             search=(RelativeLayout) findViewById(R.id.searchingcars);             textView=(TextView) findViewById(R.id.searchcars1);             close_btn=(ImageView) findViewById(R.id.search_close_btn);     //        filter_cars=(ImageView) findViewById(R.id.filter);      /*       filter_cars.setOnClickListener(new View.OnClickListener() {                 @Override                 public void onClick(View view) {                     intent=new Intent(this,Filtercars.java);                     startActivity(intent);                 }             });*/             close_btn.setOnClickListener(new View.OnClickListener() {                 @Override                 public void onClick(View view) {                     search.setVisibility(View.GONE);                 }             });             textView.setOnClickListener(new View.OnClickListener() {                 @Override                 public void onClick(View view) {                      search.setVisibility(View.VISIBLE);                 }             });         }     }   Error : Unable to start activity ComponentInfo{in.mega.sliderdrawer/in.mega.sliderdrawer.MainActivity}: java.lang.NullPointerException: Attempt to invoke virtual method 'void android.widget.ImageView.setOnClickListener(android.view.View$OnClickListener)' on a null object reference

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?


So, I don't want all my data blown away every time I turn off my system, so how would I create a storage system that doesn't use batteries but also keeps the data that I have stored?

I would like to make a simple circuit to store or save 1 bit of data. The circuit should be able to remember the state of an LED ( on or off ) even if the supply is disconnected from the circuit. I need it to work like a hard drive, flash memory or SD memory card of cell phones.  I made a circuit as shown in the picture, The output is an LED in series with 470 ohm resistor. I use two bush buttons to charge or discharge the capacitor so the output LED is on or off.   After disconnecting the supply or turning off electricity, The circuit was able to remember the state of the LED for few minutes.   After 2 or 3 minutes, the capacitor discharged completely and the circuit lost its data.    How can I stop the capacitor from discharging ? or how can I slow the rate of discharging so that the circuit lose its data after a week or more ?  In this circuit I uses 555 as an inverter ( not gate ) but I may use any other IC's , My aim is just making a simple permanent memory.


When the Jedi Council senses the rise of the dark side about a century or two  before the end of the Republic, Yoda suggested that it heralds the imminent coming of the Chosen One, prophesied to bring balance to the Force. Anakin Skywalker is confirmed to be indeed the Chosen One, but what exactly is his intended destiny?  Foremost is the Jedi belief that he will end the Sith Order once and for all. Even though he, as Vader, eventually sacrificed himself to kill Palpatine, thus ending both the master and the apprentice, the Sith Order was not truly ended. Palpatine eventually returned before dying for good, and the Sith Order under Krayt's Rule of One yet lives. Not to mention that the greatest champions of the dark side have always come from the light. If Anakin was chosen to end anything, he was extremely sloppy.  But what about the other possibility? The Father decreed that the Chosen One is meant to replace him in keeping the Son and the Daughter in balance. By choosing to leave, he had supposedly failed his destiny, allowing the Force to tilt in severe imbalance, and this consequence is supposedly revealed and only then corrected in some measure a great many years later by his son Luke.  In any case, Anakin seems like a massive failure in life. But what was his true purpose?

The legend of the Chosen One foretold the coming of a being who would restore balance to the Force.  Now we know that Anakin Skywalker was the Chosen One, but how exactly was he supposed to restore balance?  Is a balance to the Force:   eliminating all Dark Side users so that only the Light Side remains?   reducing the Dark Side's influence to almost nothing, but still leaving some Dark Side users so that there is a balance of energies? (End of Episode VI, there are still Dark Side users in Legends) creating an equal presence on both sides? (for example, at the end of Episode III it appears that there are two Sith [Sidious and Vader] and two Jedi [Yoda and Obi-Wan]) Any other way not mentioned above?   And whichever the legend means, has the prophecy been completed? Has the Chosen One restored balance to the Force at one point, or did he fail to fulfill the prophecy?  So in short, What is the meaning of 'balance' when it is said that "The Chosen One will bring balance to the Force", and did he fulfill the prophecy?


I was studying HTML and I saw that when someone is making a form the safest method is POST. So why someone should choose GET method? And when we choose GET or POST method?

I wish to know all the pros and cons about using these two methods. In particular the implications on web security.  Thanks.


I have 19.34gb unallocated space (sda7). I want this space to be added to my root partition sda11. How can I do that? I read few posts related to this but some of them suggest to use live usb and in some posts they asked only to add this command sudo resize2fs /dev/sda11. I don't know which procedure to follow. I tried to run the above command but I get this message The filesystem is already 5594368 blocks long.  Nothing to do!.  Also some posts suggested to move up or down my sda11 and then run the command but I don't know how to move sda11 up or down.   So for now I have read and tried above things. And I still don't know ho to increase/merge my root(sda11) and 19.34gb space(sda7). Please help.   Note: I am using dual boot and gparted.

I have a dual boot setup with Ubuntu and Windows 7. I need to shrink my root Ubuntu volume in order to get some free space to create a new partition. Are there any Windows based tools that will do this for me? I tried booting up in gparted to do this but I cannot tell which partition is which since I cannot find the size (it displays everything in blocks).


Does anyone know how you would type this in latex?  Thank you!

How do I produce a conditional expression with large brackets? For example: X = 0 if a=1, 1 otherwise, with a large left bracket and specifying each condition in a line?


I am trying to learn how to use multithreading in C#. I am working from , which explains using lambda expressions to pass arguments. I built a toy program to test this, but am confused by the output.  Here is my code:  using System; using System.Threading;  namespace MultithreadingApplication {    class ThreadCreationProgram    {       public static void CallToChildThread(int id)       {          Console.WriteLine(string.Format("Child thread {0} starts", id));       }        static void Main(string[] args)       {         for (int i=0; i<10; i++)         {             Console.WriteLine(string.Format("i: {0}", i));             Thread childThread = new Thread( () => CallToChildThread (i) );              childThread.Start();         }       }    } }   And here is the output:  i: 0 i: 1 Child thread 1 starts i: 2 Child thread 2 starts i: 3 Child thread 3 starts i: 4 Child thread 4 starts Child thread 5 starts i: 5 i: 6 Child thread 6 starts i: 7 i: 8 Child thread 7 starts i: 9 Child thread 9 starts Child thread 8 starts Child thread 10 starts   The Child function only prints out the value of the id it is passed. I expected these to range from 0 to 9, but CallToChildThread is instead showing 1 to 10. Can someone please explain why?

I met an interesting issue about C#. I have code like below.  List<Func<int>> actions = new List<Func<int>>();  int variable = 0; while (variable < 5) {     actions.Add(() => variable * 2);     ++ variable; }  foreach (var act in actions) {     Console.WriteLine(act.Invoke()); }   I expect it to output 0, 2, 4, 6, 8. However, it actually outputs five 10s.  It seems that it is due to all actions referring to one captured variable. As a result, when they get invoked, they all have same output.  Is there a way to work round this limit to have each action instance have its own captured variable?


There's lots of questions about it but I don't quite get it yet. I have to upload some code into a server to run 24/7, and this code will be basically something like this:    while True:     variable1 = function1()     variable2 = function2()     variable3 = function3()   So let's say I want to do variable2 = function2() once every hour or so, for performance (I don't understand much about it, but I think it'll do good to put a timer on it)    I can't use time.sleep() on it because the code has to keep going I mentioned the server thing because I don't know if answers using a system timer works with it, I'm still learning how to do it. Forgot to say I'm using Python 2.7

I'm calling a function in Python which I know may stall and force me to restart the script.   How do I call the function or what do I wrap it in so that if it takes longer than 5 seconds the script cancels it and does something else?


Are iTunes music purchases still available once I change the store country, assuming that both stores offer the same content which is associated with my account?  I am just concerned about making a substantial investment in music purchases now and not having the ability to download the files after crossing borders.

I lived in country A for a few years, and made a number of purchases on the iTunes store for that country. I have now moved to country B, and want to start using the iTunes store from country B. If I change the country in my account settings, will I lose all my previous purchases, or will I still be able to re-download my purchases from country A from iCloud?


I've read about it, checked a few youtube videos about the subject but I still can't understand the process.  What is it that makes high voltage + AC current a better process to transport energy? I have seen formulas, but I need to understand how it works conceptually first.  If we use High Voltage (to cope with the resistance over a long distance) together with DC current a lot of energy is lost due to the continues resistance and the same happens with AC, so how is that one is better that the other one?  The only difference I can see, is the relief on the cables because of the polarity switch, is that why AC is better to transport electricity over long distances? Please don't use formulas to explain it, I need to understand how it all works first.  And if the voltage is higher how can the current be lower? I mean, there's a stronger force to push the electrons, so shouldn't it be the opposite?

I have difficulties with understanding high voltage transmission and transformers working process. Particularly with this expression: "the higher the transmission line voltage, the smaller the current".  I will try to explain:  The first case - we have usual line transmission, without transformers:   Here is all straightforward: we have circuit, with   R = 50 Ω;  V = 1000 v;  I = 20 A   Everything is clear and understandable.  Now, the second case - we have high voltage line transmission with transformers:   Two trasformers was added: step up and step down. Why it was done? I know the answer, it is wrote everywhere on the internet - it was done, to decrease current in transmission line, in order to reduce losses, caused by high current. Voltage have increased, but power should stay the same, therefore current should be decrease, the formula P = I*V, Joule-Lenz law... etc. It's all clear.  But! Now we are have potential difference 10 000 volt in our transmission line. Resistance stays the same. Apply Ohm's law and get:  \$I = \frac {10000v}{20 Ω} = 500 A\$  500 amperes instead of 20 amperes in the first scheme. I understand, that it can't be the truth, because then there would not high voltage lines existence. But where I made error?  Edit1:  I have found good discussion on this topic . They working on this question thoroughly. Look there, if you are interested in the detailed answer too (first three pages needed to read).  Edit2:  Can anyone explain this moment:    We are turn on generator (AC source)  It starts produce AC current This action affects step up transformer by the magnetic field on its primary coil and step up transformer start works too, generating current on its secondary coil. Then current goes to the high voltage line After high voltage line, it comes to the step down transformer Step down transformer starts work too And only now is the turn of ‘Load’.   What I think - ‘Load’ is passive entity, it is take what it is given. How it can dictate and regulate magnitude of current which pass through high voltage line? 'Load' just sits on its place and waits what current will be on the step down transformer and uses, what has come. It can't sucks current, how it want. Furthermore, even if ‘Load’ turned off, circuit will closed and will work. Right?  In the first case (without transformers), we are not having closed circuit, before ‘Load’ is turned on. But in the second case we have closed circuit without 'Load'.  Second question: how ‘Load’ can determines and affects to the current in the high voltage line, when it is passive entity (in my opinion)? Is the current in the high voltage line depends from the load after step down transformer?  Found answer to the second question . Very good article.


It would be nice if sites had a link to StackExchange's main site. I find myself regularly editing my address bar's contents just to do something websites used to do as a unwritten rule.

One thing I've noticed about the relatively new sitewide layout is that I can't find a quick way to get back to www.stackexchange.com without finding StackExchange in the sites list. As a result, I am typing stackexchange in my toolbar a whole lot more often now. In particular, I tend to enjoy browsing the hot questions list and my own personal feed quite often so visit these pages on a daily basis. Is there an easy link to them that I'm missing?  (On the android app, there is a feed in the menu that I really appreciate, something like that on the desktop would be ideal!)


Currently have a Windows 7 Ultimate on my Notebook with Bitlocker encrypting the drive. I just have a normal 160GB hard drive now. Just ordered a SSD to replace it. Should i just suspend bitlocker before i upgrade my drive (remember had to do this when i upgraded the bios) or should I totally remove drive encryption before i start?

I have laptop with Windows 7. The whole drive is encrypted with Bitlocker. I want to switch magnetic hard drive to SSD. How can I mirror the entire system onto the SSD with the LEAST amount of user attention? Ideally, I'd like to be able to just pop the SSD into the laptop and get on with the life


I would like to go about the end of October to Tromsø, but it is not clear if there is enough snow for husky rides. Do you recommend it?  Also I do not know if it is reasonable to book it since now or can be done easily on the arrival at the hotel. Any recommendation?

I am interested in hiking this fall in France and camping along the way. In order to figure what gear I need to pack to camp (particularly for the sleeping bag), I would like to know what temperatures to expect.  I am interested in historical temperatures to figure the usual temperature and I might look at them for other seasons. If that matters, I am thinking about hiking in the Pays Basque (South West of France), the mountainous part.  Where (ideally online and for free) can I find such data? Are there resources that cover Europe, or even the whole world?


In one of my research projects, I found a negative correlation between $X$ (a regressor of interest) and $Y$ (an outcome variable). In the regression model, I found that the coefficient of $X$ is positive after controlling for other variables in the regression model.   What could be the explanation of the negative correlation in the unadjusted model? I expected that a negative correlation would yield a negative regression coefficient in the multivariate model.

The coefficient of an explanatory variable in a multiple regression tells us the relationship of that explanatory variable with the dependent variable. All this, while 'controlling' for the other explanatory variables.  How I have viewed it so far:  While each coefficient is being calculated, the other variables are not taken into account, so I consider them to be ignored.   So am I right when I think that the terms 'controlled' and 'ignored' can be used interchangeably?


So, I'm doing homework.  I've encountered something I haven't seen before and cannot find a decent explanation of what it does.  Basically,  Object object; ... while((value1, value2) = function(object)) {     object.foo(value1, value2); }   The (value1, value2) in the while statement really throws me.  Any ideas?

How does the comma operator work in C++?  For instance, if I do:  a = b, c;     Does a end up equaling b or c?   (Yes, I know this is easy to test - just documenting on here for someone to find the answer quickly.)  Update:  This question has exposed a nuance when using the comma operator.  Just to document this:  a = b, c;    // a is set to the value of b!  a = (b, c);  // a is set to the value of c!   This question was actually inspired by a typo in code.  What was intended to be  a = b; c = d;   Turned into  a = b,    //  <-  Note comma typo! c = d;


How can I reach the UI to configure the autostart applications in Ubuntu 11.10? Please don't tell me, I have to do it using the terminal or creating a starter on my own and please don't tell me, it is gone!

How can I make an application automatically start when I have logged in?


How come authors go missing in my bibliography? It happens for some articles, but never for books or incollections.    This is test.bib  %%% WORKS @article{zarrinbakhsh:improving,  author = {Zarrinbakhsh, Nima and Mohanty, Amar K. and Misra, Manjusri},  year = {2013},  title = {Improving the interfacial adhesion in a new renewable resource-based biocomposites from biofuel coproduct and biodegradable plastic},  pages = {6025--6038},  volume = {48},  number = {17},  journal = {Journal of Materials Science} }  %%% DOESN'T WORK @article{schmid:autoxidation,  author = {Schmid, Manfred and Ritter, Axel and Grubelnik, Andreas and Zinn, Manfred},  year = {2007},  title = {Autoxidation of medium chain length polyhydroxyalkanoate},  pages = {579--584},  volume = {8},  number = {2},  journal = {Biomacromolecules} }   This is test.tex  \documentclass{scrreprt}  \usepackage[     backend=bibtex,     natbib=true,     defernumbers=true]{biblatex} \addbibresource{test.bib}  \begin{document}      This should have more than one author~\citep{schmid:autoxidation}.      This has more than one author~\citep{zarrinbakhsh:improving}.      \printbibliography  \end{document}

I'm using the  package to add citations and a bibliography to my LaTeX document. I've noticed that only the first author plus "et al." is displayed for works with more than three authors. That's fine with me for in-text-citations, but I'd rather have the complete author information in the bibliography. How can I do that?


I have a price= method inside a Ticket class, which sets a price only if it has at most two values after the decimal point:-  def price=(price)     if (price*100).to_i == price*100           @price = price     else           "The price format is off!"     end end   Now, when I add the code puts price=(50.75543), I'm getting 50.75543 as the output. There are two questions which come to my mind:-   Why does the code even work? The method call isn't valid as such (I tried the same with the method name set_price instead of price= and it throws an error), as I haven't even created an instance of the Ticket class. It's almost as if the price= method is being treated as a variable assignment. Even if the code is puts t.price=(50.75543), where t is an instance of the Ticket class, the output is 50.75543. Why is this so? How do I get it to output "The price format is off!"?

Let's say I have a Ruby class:  class MyClass   def self.property     return "someVal"   end    def self.property=(newVal)     # do something to set "property"     success = true      return success # success is a boolean   end end   If I try and do MyClass.property=x, the return value of the whole statement is always x. It is a convention in a lot of C-based/inspired languages to return a boolean "success" value - is it possible to do this for a setter using the "equals syntax" in Ruby?  Furthermore - if this isn't possible, why not? Is there any conceivable downside to allowing an "equals setter" operation return a value?


I remember reading this over 15 years ago, and feel it was old even then.  The story had a man sent to a planet for some reason (survey maybe?) and discovering that there are evolved life-forms on there, of a mechanical nature. They use solar energy to survive so effectively shut down overnight. There are night time predators that attack, and he shows them how to create batteries to fend them off.  During the story the robots talk about what is obviously infra-red and ultraviolet light, and one day he wakes up to find he can see in those spectra. He asks how they "fixed" his eyes, and gets shocked when one of the robots opens a drawer in it's body to show that they actually replaced them.  I seem to remember that the cover had a man in a spacesuit surrounded by huge crystals.

I trying to remember the name of a book I read 20 or 30 years ago. A man is stranded on an alien world.  He gets badly injured and a bug like alien heals him by creating a organic heart.  The aliens are solar powered and must wall themselves off at night for protection from predators. All their technology is based on organics.  The human shows them a battery and they are able to modify their bodies to have organic batteries and stay awake at night.


If I want to prove that $A_n$ is a normal subgroup of $\:S_n$ I know how to prove that $A_n$ is a subgroup, but if I want to prove that it is a normal subgroup. Can I prove like that: Let  $f_1\in S_n$ then we need to provef that: $f_1A_n=A_nf_1$. $\DeclareMathOperator{\sign}{sign}$ So we know that: $\forall h\in A_n:\:\sign\left(f_1\:\circ \:h\right)=\sign\left(f_1\right)\cdot \sign\left(h\right)=\sign\left(f_1\right)$ On another hand: $\forall h\in A_n:\:\sign\left(h\:\circ f_1\right)=\sign\left(h\right)\cdot \sign\left(f_1\right)=\sign\left(f_1\right)$ Because we know that $\sign(h)=1$ So we can say that: $f_1A_n=A_nf1$ Is this correct?

For an exercise, I need to prove that the alternating group $A_n$ is a normal subgroup of the symmetric group $S_n$.  As clue they say we can use a group homomorphism $\operatorname{sgn} : S_n \to \{-1,1\}$. I really don't see how i can use this.... can somebody help?


This is not a duplicate as the thread mentioned as duplicate only tells you why to not use System.gc(), while I do know that, that's not my question.  Using System.gc() or Runtime.getRuntime().gc() won't always execute garbage collection, it just requests it and it can even be ignored by the JVM.   Is there a reason behind this? Is it "random"? Since I don't think random even exists in programming, I'm curious why it sometimes doesn't collect it, and sometimes does and also at different times.

I know that garbage collection is automated in Java. But I understood that if you call System.gc() in your code that the JVM may or may not decide to perform garbage collection at that point. How does this work precisely? On what basis/parameters exactly does the JVM decide to do (or not do) a GC when it sees System.gc()?  Are there any examples in which case it's a good idea to put this in your code?


Would a Patronus animal change throughout your life, if different things make you happy to what you used to like?

My friend and I were talking about this. The only two instances mentioned in which patronuses change into a loved one's patronus, is when the love is unrequited (Snape to Lily, Tonks to Lupin). My friend thinks a wizard's patronus only changes with unrequited love, while I think that is too specific and weird.     "You'd better put that cloak back on, and we can walk up to the school" said Tonks, still unsmiling. As Harry swung the cloak back over himself, she waved her wand; an immense silvery four-legged creature erupted from it and streaked off into the darkness.   "Was that a Patronus?" asked Harry, who had seen Dumbledore send messages like this.   "Yes, I'm sending word to the castle that I've got you or they'll worry. Come on, we'd better not dawdle."      The Half-Blood Pricne - page 157 & 158 - Bloomsbury - chapter 8, Snape Victorious        "Hagrid was late for the start-of-term feast, just like Potter here, so I took it instead. And incidentally," said Snape, standing back to allow Harry to pass him, "I was interested to see your new Patronus."      The Half-Blood Pricne - page 160 - Bloomsbury - chapter 8, Snape Victorious        "But I don't care either, I don't care!" said Tonks, seizing the front of Lupin's robes and shaking them. "I've told you a million times...."   And the meaning of Tonks's Patronus and her mouse-colored hair, and the reason she had come running to Dumbledore when she had heard a rumour someone had been attracked by Greyback, all suddenly became clear to Harry; it had not been Sirius that Tonks had fallen in love with after all.      The Half-Blood Prince - page 624 - Bloomsbury - chapter 29, The Pheonix Lament   And...     "But this is touching, Severus," said Dumbledore seriously. "Have you grown to care for the boy, after all?"   "For him?" shouted Snape. "Expecto Patronum!"   From the tip of his wand burst the silver doe: She landed on the office floor, bounded once across the office, and soared out of the window.      Deathly Hallows - page 687 - Bloomsbury - chapter 33, The Prince's Tale   But if it changed for any love, wouldn't that mean that couples would end up with the same patronuses? For example, if Lily fell in love with James, couldn't her patronus become a stag, which in turn would make Snape's a stag, too? And is it only romantic love? Does a parent's patronus change to their child's? But then that seems way too general. Everyone would have the same patronus.   Is this only strong, passionate love? But how would that be judged? That would put down all other kinds of love.   (edit: I know Lupin did love Tonks back, but as , he was still rejecting her)


I've found an interesting floating point problem. I have to calculate several square roots in my code, and the expression is like this:  sqrt(1.0 - pow(pos,2))   where pos goes from -1.0 to 1.0 in a loop. The -1.0 is fine for pow, but when pos=1.0, I get an -nan. Doing some tests, using gcc 4.4.5 and icc 12.0, the output of   1.0 - pow(pos,2) = -1.33226763e-15   and   1.0 - pow(1.0,2) = 0   or  poss = 1.0 1.0 - pow(poss,2) = 0   Where clearly the first one is going to give problems, being negative. Anyone knows why pow is returning a number smaller than 0? The full offending code is below:  int main() {   double n_max = 10;   double a = -1.0;   double b = 1.0;   int divisions = int(5 * n_max);   assert (!(b == a));    double interval = b - a;   double delta_theta = interval / divisions;   double delta_thetaover2 = delta_theta / 2.0;   double pos = a;   //for (int i = 0; i < divisions - 1; i++) {    for (int i = 0; i < divisions+1; i++) {      cout<<sqrt(1.0 - pow(pos, 2)) <<setw(20)<<pos<<endl;       if(isnan(sqrt(1.0 - pow(pos, 2)))){       cout<<"Danger Will Robinson!"<<endl;       cout<< sqrt(1.0 - pow(pos,2))<<endl;       cout<<"pos "<<setprecision(9)<<pos<<endl;       cout<<"pow(pos,2) "<<setprecision(9)<<pow(pos, 2)<<endl;       cout<<"delta_theta "<<delta_theta<<endl;       cout<<"1 - pow "<< 1.0 - pow(pos,2)<<endl;       double poss = 1.0;       cout<<"1- poss "<<1.0 - pow(poss,2)<<endl;     }    pos += delta_theta;  }   return 0;  }

Consider the following code:   0.1 + 0.2 == 0.3  ->  false   0.1 + 0.2         ->  0.30000000000000004   Why do these inaccuracies happen?


I am trying to update the repository  in Ubuntu 16.04 in Oracle VM Virtual  Box, I am getting the below message and it is not completing  0% connecting to security.ubuntu.com(91.189.88.162).  I tried disabling ipv6  but still I am getting the same error. Can anyone help me how to resolve this issue?   I want to install Hadoop on Ubuntu.  However I am stuck at first step while updating the repository.  Thanks, Vijaya

When I do upgrade it gets stuck here:  user@plato:~# sudo apt-get upgrade Reading package lists... Done Building dependency tree        Reading state information... Done Calculating upgrade... Done The following packages will be upgraded:   bind9-host coreutils cpio curl dnsutils libbind9-90 libc-bin libc-dev-bin   libc6 libc6-dev libcgmanager0 libcurl3 libcurl3-gnutls libdns100   libdrm-intel1 libdrm-nouveau2 libdrm-radeon1 libdrm2 libisc95 libisccc90   libisccfg90 libjasper1 liblwres90 libplymouth2 libsepol1 libssl-dev   libssl-doc libssl1.0.0 linux-libc-dev mime-support multiarch-support ntp   ntpdate openssl plymouth plymouth-theme-ubuntu-text python3-distupgrade   ubuntu-release-upgrader-core unzip 39 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. Need to get 16.0 MB of archives. After this operation, 12.3 kB of additional disk space will be used. Do you want to continue? [Y/n] y 0% [Connecting to us.archive.ubuntu.com (2001:67c:1562::15)] ░   When I do update it gets stuck here:  user@plato:~# apt-get update 0% [Connecting to us.archive.ubuntu.com (2001:67c:1562::14)] [Connecting to sec░   I'm able to ping us.archive.ubuntu.com just fine:  user@plato:~# ping us.archive.ubuntu.com PING us.archive.ubuntu.com (91.189.91.23) 56(84) bytes of data. 64 bytes from economy.canonical.com (91.189.91.23): icmp_seq=1 ttl=54 time=81.5 ms 64 bytes from economy.canonical.com (91.189.91.23): icmp_seq=2 ttl=54 time=81.5 ms 64 bytes from economy.canonical.com (91.189.91.23): icmp_seq=3 ttl=54 time=81.5 ms 64 bytes from economy.canonical.com (91.189.91.23): icmp_seq=4 ttl=54 time=81.4 ms ^C --- us.archive.ubuntu.com ping statistics --- 4 packets transmitted, 4 received, 0% packet loss, time 3004ms rtt min/avg/max/mdev = 81.425/81.528/81.582/0.355 ms   What can i do to fix this?    What I have tried so far.  I've tried following directions on this blog:   To force apt-get to use IPv4 exclusively   Create a file in /etc/apt/apt.conf.d/99force-ipv4 Add this line to newly created file Acquire::ForceIPv4 false; Apt-get will now use IPv4 exclusively


So I'm new to javascript and I am trying to make a basic appointment sort of app. So my project contains 2 phases: 1 is to add an entry and 2 is to remove an entry Everything is working fine till phase 1, but I can't add the event listener to initiate phase 2 Here's my code:   const list = document.getElementById('app-list'); const form = document.querySelector('form');  form.addEventListener('submit', formSubmit);  function formSubmit(e) {   e.preventDefault();   let name = document.getElementById('name').value;   let date = document.getElementById('date').value;   // Now that we have the data Submitted, let's make the element!   let entry = document.createElement("tr");   entry.innerHTML = `<td>${name}</td><td>${date}</td><td><div class="red-box"><h1>X</h1></div>`;   list.appendChild(entry); } var removebtn = document.getElementsByClassName('red-box');  for (i = 0; i < removebtn.length; i++) {   removebtn[i].addEventListener('click', removeEntry, false); }  // Adding Event listner to the removeBTN function removeEntry(e) {   console.log('hello World'); }
   <form>
       Appointment Name
       <input id="name" type="text" name="name" placeholder="Appointment name.." required>

       <lable for="date">Appointment Date</lable>
       <input id="date" type="date" name="date" placeholder="Appointment Date.." required>

       <input type='submit' value="add">
   </form>

         Name	         Date

I have a bit of code where I am looping through all the select boxes on a page and binding a .hover event to them to do a bit of twiddling with their width on mouse on/off.  This happens on page ready and works just fine.  The problem I have is that any select boxes I add via Ajax or DOM after the initial loop won't have the event bound.  I have found this plugin (), but before I add another 5k to my pages with a plugin, I want to see if anyone knows a way to do this, either with jQuery directly or by another option.


During my course on elementary set theory, we defined $\omega_1$ to be the set of all countable ordinals. Now with Foundation we know that $\omega_1$ cannot be countable since that otherwise means $\omega_1\in \omega_1$, which just violates Axiom of Foundation. Now the question is can we prove $\omega_1$ is uncountable without using Foundation? How should I proceed? This was a past paper question that did not worth so many marks and so I was wondering if there is a really slick way of showing this. I thought about using the criterion that a set is countable if and only if there exists a surjective function from $\omega$ to this set / if and only if there exists an injective function from this set to $\omega$ but I am stuck after some initial thoughts. Many thanks in advance for any helps!

I would like to show that the successor set of an ordinal: $s(\alpha) =\alpha \cup\{\alpha\}$ is an ordinal. To do so, I need to show that that $S(\alpha)$ is strictly well-ordered by $\in$.  I can't seem to show that $\alpha \notin \alpha$.


Eyery single tkinter import creates a tkinter window with a winged sign   on the top. Here's a screenshot:  Any ideas how to remove it? Thanks in advance!  I need the answer for Windows, not for UNIX

How to remove tkinter icon from title bar in it's window


Is it true that a field is a vector space over a field?  This idea arises in me after reading the solution for the question the order of finite field is $p^n$.    I am wondering if it is possible to not consider subfield but just a field as a vector space over a field.  In fact, I don't quite get why a field is a vector space over its subfield. Why can't it be other fields?  I am having a lot of confusion here.

Are $\mathbb{Z_p},\mathbb{Q},\mathbb{R},\mathbb{C}$ above themselves vector space? Is a field above anoother field a vector space?   As for 1. we know that $\Bbb R^n$ is a vector space so in particular it is true for $n=1$  For 2. by definition a vector space is $V$ with addition and multiplication over a field, therefore 2 is true.


Here is an exercise of the book commutative algebra by Atiyah and MacDonald (Ex 2.13):  Let $ f : A \rightarrow B$ be ring homomorphism and $N$ be  a $B$ module. Regarding $N$ as a $A$ module by restricting the scalars, and form the $B$ module $N_{B} = B \otimes N$ (tensor over $A$). Then the homomorphism $g : N \rightarrow N_{B}$ which maps $y$ to $ 1 \otimes y $ is injective and $g(N)$ is  a direct summand of $N_{B}$. i.e. $N_{B} = L \oplus g(N)$  for some $B$ module $L$.  I think I am not understanding this statement in the following way: let's take $B$ to be any ring containing a field $k$, let's $N$ be any $B$ module, by restricting the scalars to $k$, it becomes $k$ module hence free module therefore projective, then $N_{B}$ becomes projective $B$-module therefore any direct summand is projective which implies that $N$ is projective $B$ module, which is completely absurd because $N$ was any $B$ module. Where is the flaw? Any help would be great.

Let $f \colon A \to B$ be a ring homomorphism, and let $N$ be a $B$-module. Regarding $N$ as an $A$-module by restriction of scalars, form the $B$-module $N_B = B \otimes_A N$. Show that the homomorphism $g \colon N \to N_B$ which maps $y$ to $1 \otimes y$ is injective and that $g (N)$ is a direct summand of $N_B$.   [Define $p \colon N_B \to N$ by $p (b \otimes y) = by$, and show that $N_B = \operatorname{Im} (g) \oplus \operatorname{Ker} (p)$.]   My idea was to define an isomorphism \begin{align*} \phi \colon N_B & \to \operatorname{Im} (g) \oplus \operatorname{Ker} (p) \\ b \otimes y & \mapsto (p (b \otimes y), b \otimes y - 1 \otimes (g \circ p) (b \otimes y)) \end{align*}  It's easy to check that $\phi$ is injective and surjective. If I take the $B$-module structure of $N_B$ to be $$ b' . (b \otimes y) = (b'b) \otimes y $$ I only manage to show that $\phi$ is a homomorphism of $A$-modules, because $g$ seems to be only a homomorphism of $A$-modules: $$ b.g(y) = b.(1 \otimes y) = b \otimes y \neq 1 \otimes (b.y) = g (b.y) $$ (where $\neq$ means "not equal in general").  However, the way the question is phrased seems to suggest that the isomorphism should be one of $B$-modules.  Should I take the $B$-module structure of $N_B$ to be something else, for example $$ b'.(b \otimes y) = b \otimes (b'.y) $$ or should I show the result only for $A$-modules?  I've been confusing myself about this issue of "as $A$-module" or "as $B$-module" and would appreciate if someone could clarify. (I also wonder if, since homomorphisms are only fancy functions of sets, it somehow doesn't matter.)


I had Linux Mint 16 with English and Russian keyboard support. Upgraded to Mint 17, now I cannot get past the ecryptfs passphrase.  If I enter Grub loader I can pick "Ubuntu with Linux 3.11.0.12-generic" and I am able to enter passphrase (latin characters) but when I get to Login Screen it only types in Russian. I changed the language to US English, British English, but it has no effect. Characters are still in Russian. (see )  I have searched LinuxMint forums up and down...fruitless.  Recovery console also drops into Russian and I cannot login either. so basically I have no access to system whatsover.  Also: I have tried "e" grub, and set locale=en_US.UTF-8 .........NO SUCCESS I have tried LANG=en_US.UTF-8 ............ same crap I have even tried passing en_US.ASCII to kernel.... still nothing.  Is there a way to pass charset UTF-8 in Grub config to kernel?

After installing Mint 15 / updating to Mint 17, I'm unable to log in using the GUI login screen and German localisation with a password containing special characters. Changing the language using the language selector doesn't help.  It seems to be an issue regarding the window manager (mdm), since I'm able to log in using a text console (e.g. using ALT+CTRL+F1).  Adapting the file /etc/default/keyboard (as ) or  didn't change anything.


What is going on here in this line:     -1[0[ptr]][0]

As Joel points out in , in  (aka: K & R), there is mention of this property of arrays in C: a[5] == 5[a]  Joel says that it's because of pointer arithmetic but I still don't understand. Why does a[5] == 5[a]?