One of my friends wanted to have more logs in the /var/log/ directory, and after some time of using the system, he tried to access the folder and list it, but instead he got the following error:  bash: /bin/rm: Argument list too long   Does anyone know how many files can be added to this rm list?

I was under the impression that the maximum length of a single argument was not the problem here so much as the total size of the overall argument array plus the size of the environment, which is limited to ARG_MAX. Thus I thought that something like the following would succeed:  env_size=$(cat /proc/$$/environ | wc -c) (( arg_size = $(getconf ARG_MAX) - $env_size - 100 )) /bin/echo $(tr -dc [:alnum:] </dev/urandom | head -c $arg_size) >/dev/null   With the - 100 being more than enough to account for the difference between the size of the environment in the shell and the echo process. Instead I got the error:  bash: /bin/echo: Argument list too long   After playing around for a while, I found that the maximum  was a full hex order of magnitude smaller:  /bin/echo \   $(tr -dc [:alnum:] </dev/urandom | head -c $(($(getconf ARG_MAX)/16-1))) \   >/dev/null   When the minus one is removed, the error returns. Seemingly the maximum for a single argument is actually ARG_MAX/16 and the -1 accounts for the null byte placed at the end of the string in the argument array.  Another issue is that when the argument is repeated, the total size of the argument array can be closer to ARG_MAX, but still not quite there:  args=( $(tr -dc [:alnum:] </dev/urandom | head -c $(($(getconf ARG_MAX)/16-1))) ) for x in {1..14}; do   args+=( ${args[0]} ) done  /bin/echo "${args[@]}" "${args[0]:6534}" >/dev/null   Using "${args[0]:6533}" here makes the last argument 1 byte longer and gives the Argument list too long error. This difference is unlikely to be accounted for by the size of the environment given:  $ cat /proc/$$/environ | wc -c 1045   Questions:   Is this correct behaviour, or is there a bug somewhere? If not, is this behaviour documented anywhere? Is there another parameter which defines the maximum for a single argument? Is this behaviour limited to Linux (or even particular versions of such)? What accounts for the additional ~5KB discrepancy between the actual maximum size of the argument array plus the approximate size of the environment and ARG_MAX?   Additional info:  uname -a Linux graeme-rock 3.13-1-amd64 #1 SMP Debian 3.13.5-1 (2014-03-04) x86_64 GNU/Linux


I want to set default values if not specified by user. eg, for Boolean private isValid , if we don't specify any json value, then it should set false . I am using hibernate validator, @NotNull, @NotBlank, @Size, @Range...Is there any annotations to set default value for boolean, int, float, irrespective of data types. I tired hard, but did not come up with any solution. Still I am trying..Your help is highly appreciated ! Thank you

Is it possible to set a default value for columns in JPA, and if, how is it done using annotations?


The question is prove by induction that $2^n\le n!$ for all $n\ge 4$ So far I have completed the base case so, Base case $n=4$ $ 2^4\le4!$ $16\le24$ Therefore the base case holds Inductive Step Assume F(n) is true $2^{n+1}\le (n+1)!$ $2^{n+1}\le n!(n+1)$ $2\cdot 2^n \le n!(n+1)$ <- I don’t know what do after this to get New Approach $2\cdot n!\le n!(n+1)$   $ by F(n) $ $2^{n+1}\le (n+1)!$

I'm having difficulty solving an exercise in my course.  The question is:      Prove that $n!\geq 2^n$.   We have to do this by induction. I started like this:   The lowest natural number where the assumption is correct is $4$ as: $4! \geq 2^4 \iff 24 \ge 16$. The assumption is: $n! \ge 2^n$.   Now proof for $(n+1)$ which brings me to: $(n+1)! \ge 2^{(n+1)}$  I think I can rewrite it somehow like this:  $$ {(n+1)} \times {n!}  \stackrel{\text{(definition of factorial)}}{\ge} 2^n \times 2 $$  $$ (n+1) \times 2^n \ge 2^n \times 2 $$  Then I think I can eliminate the $2^n$ and have something like this: $n+1 \ge 2$, or $n \ge 1$.  But I think I'm wrong here some where and was hoping somebody has some advice on this. How can I prove the above assumption?  Any help would be appreciated, kind regards.


In a badminton singles tournament, each player played against all the others exactly once and each game had a winner. After all the games, each player listed the names of all the players she defeated as well as the names of all the players defeated by the players defeated by her. For instance, if A defeats B and B defeats C, then in the list of A both B and C are included. Prove that at least one player listed the names of all other players.

Can you prove via induction that there exists a node in a directed graph of n nodes that can be reached in at most two edges from every other node in the graph. Every node in the graph is required to have an edge with every other node that either points out or in (For every pair of nodes X and Y, either X points to Y or Y points to X).


Firstly:    Enter my email address, then hit enter takes me to:    Feels like it's unnecessarily staggered, but maybe I'm missing something? This is a relatively new occurrence as well

I am not asking about the two factor authentication process where the user needs to enter both a password and a one-time-password.  Gmail recently (I don't know from when exactly) changed their login process which is depicted in the following screenshot:     So, the new steps are as follows:   Enter email   Click Next  Enter password   Click Sign In    as opposed to the previous and usual way of logging in:   Enter email and password   Click Sign In    Isn't the new process non-user friendly requiring extra user interactions?  Since, Google does not usually make UX blunders can you explain the reasoning behind the new process? I'm looking for details like user interaction simplicity or any other hidden advantages.  Note: The question  doesn't cover the reason behind the change while Mervin Johnsingh's answer cites Google's reason.


I want to know, with regex, if a list is well-written or not. A well-written list start with '[' and ends with ']' and can handle numbers or other lists or be empty. Example of valid lists: [1, 2, 3] [1, [6, 9], 4] [[1, 5], 2, [2, 7, [[]], 8, 9, [1]], []]  As you can see this is recursive. So, What regular expression should I use in this case?

I need a regular expression to select all the text between two outer brackets.  Example: some text(text here(possible text)text(possible text(more text)))end text  Result: (text here(possible text)text(possible text(more text)))


Many people often post possibly correct answers as comments, because they're not sure if it's correct and don't want to receive downvotes. However, these comments often are correct and this causes problems, as a comment cannot be marked as an answer.  As an answer, it could be deleted if it's not helpful, but then it would just waste time and could be marked correct by the person asking the question because they don't fully understand the topic (the entire reason why they're asking the question).  Would it be better to post a possibly correct answer as an answer or as a comment? ...or not post anything at all?

Why do some people post comments that are actually answers to the question? Wouldn't posting an answer be better?


I need a set-builder notation for $\{1 , 3 , 5 , -7 , -9 , -11 , 13 , 15 , 17 , \ldots\}$. It is an infinite set of odd positive integers, which are multiplied by $-1$ three by three. One of the terms of this question is not to use floor function.

I want an alternating series formula that generates three negatives and three positives together.I know that we can do the same except that it is two negative and three positive can performed by triangle numbers.(See the link below.But I cannot find anything that generates three negative and three positive.For this we should do three odd and three even series and then put it in the power of $-1$.  Recommended:  update1:The series:${1,1,1,-1,-1,-1,1,1,1,-1,-1,-1,...}$  update2:We didn't learned floor function or trigonometry yet.


I need to put tables of contents on the beginning of the document and also at the last page. When I am using \tableofcontents second time it appears empty.  I want to achieve:  \documentclass{article}  \usepackage{fontspec} \setmainfont{Arial}  \begin{document}  %first toc \tableofcontents  \section{Test} test test  \section{Test 2} test test  \newpage  %second toc - generates empty \tableofcontents  \end{document}   How can I achieve the same toc on the last page?

I am using also titletoc to improve how my table of contents. I would like to print the table of contents several times. How can I do it?  It does not work in the MWE:  \documentclass{article} \usepackage[utf8]{inputenc}  \begin{document}  \tableofcontents  \section{Hello} \section{Bye}  \tableofcontents  \end{document}     PS: I have this code in my document, in order to have no title for the table of contents.  \makeatletter \renewcommand\tableofcontents{%     \@starttoc{toc}% } \makeatother   PPS: \renewcommand{\contentsname}{}% Remove \tableofcontents' title/name will not work since I am using [french]{babel}.


..and will that have any effect?  Currently, I want all of my contributions on StackExchange to be available not just under SE's licensing terms (that goes without saying), but also under a version of "Unless you're preventing other people from using it, fair game" kind of license.  Is that legally somehow possible without rehosting all of my content on say github?  To elaborate: I want people to be able to do anything they want with my code, without attribution, and the only thing they shouldn't be able to do is prevent other people from using my code. That means that I don't need or want credit and that the code can be used as much as anyone desires in any application.

With all the changes to licensing currently being discussed is it acceptable to edit my questions/answers to include a footnote.     This question/answer is provided .   I know some people are suggesting that this might be placed in a profile, but until I review all my content I don't want to blanket CC0 everything.


I would like to make some test with different node trees in Animation nodes. Is there a way to deactivate the entire page/node tree? Is it possible to deactivate nodes all in one shot, like (select all and hide or deactivate)? How do you manage the nodes when you do some test? When you don't want to erase them but just deactivate them for a while without unlinking them? I tried M to mute without success nothing happen the node stay the same colour there is no way to know if it worked.

Just wonder whether subprograms can be totally muted in ways other than just deleting it. I ask bacause:  For example, I tried to setup a loop in another nodetree, Then disable auto execution for that nodetree. However, it can still be invoked in other nodetrees, because subprograms seem to be kinda "global" data.  In some cases I want to mute the subprogram to improve overall performance by disabling the execution. Is that helpful? Can I do that? Or other better solutions? Thanks!


I usually catch up with whatever I last did on the Stack Exchange sites, by visiting . However, over the last week or two, that page is often blank, even though the tabs other than "all" ("accepts", "posts", "comments", etc.) are not.  Here's a screenshot:    The corresponding activity pages on individual Stack Exchange sites (Stack Overflow, Math.SE, etc.) are fine.

For some users, the activity tab is empty ("no activity found") if "all" is selected, even though the tabs other than "all" are non-empty.  Also, the "all" tab is loading much slower than usual for the users with an empty "all" tab. As of now:  - Empty  - Empty  - Working normally


For a project of mine I would love to provide auto completion for a specific textarea.  Similar to how intellisense/omnicomplete works.  For that however I have to find out the absolute cursor position so that I know where the DIV should appear.  Turns out: that's (nearly I hope) impossible to achieve.  Does anyone has some neat ideas how to solve that problem?

I am using jQuery and trying to find a cross browser way to get the pixel coordinates of the caret in <textarea>s and input boxes such that I can place an absolutely positioned div around this location.  Is there some jQuery plugin? Or JavaScript snippet to do just that?


Suppose I have a table with pagination due a lot of row entries. Should the default action for 'Select all' select the entries on the current page or all entries in the entire table (i.e. all pages)?   What is the intended behaviour for a user?   I am aware of the solution that Gmail has to address this where it selects the ones in view and prompts an action to select all. Just wondering where I could find some other examples of products tackling this.

Suppose I have a list of 100+ pieces of data that I'm displaying in a table that's paginating 40 elements per page.  Each row has 'select' checkbox that enables the user to select/unselect an individual item. On top of the list, there's also a 'select/unselect all' checkbox. For the moment, I have the functionality designed so that when the user clicks that checkbox, the action of toggling the selection is performed only on the elements currently displayed in the page. What are the best practices on 'select all'?  Should the action operate on:   a) only the visible elements being paginated, or   b) the entire list?


If you've ever used Google's Custom Search engine that provides search results specific to your website, you'll know what I mean.   I'm interested in an API that I can use from Stack Exchange to host a forum specifically for my website.   So for example, if I visit forum.example.com, the page would be generated / hosted by Stack Exchange and use Stack Exchange's network but on my website only.   That would mean I don't have to write a forum page myself and take advantage of Stack Exchange's huge userbase.   Is there an API or something similar like this?

Since the source code for this site isn't available for purchase or external use, I'm looking for software that can run a Q&A environment similar to Stack Exchange. Are there any such pieces of software available?


l = [1,2,3,4,5,6,7,8,9,10]   I have a list and I need to print 5 elements per line to get:  1 2 3 4 5 6 7 8 9 10   I tried everything but I'm stuck, help!

I have a list of arbitrary length, and I need to split it up into equal size chunks and operate on it. There are some obvious ways to do this, like keeping a counter and two lists, and when the second list fills up, add it to the first list and empty the second list for the next round of data, but this is potentially extremely expensive.  I was wondering if anyone had a good solution to this for lists of any length, e.g. using generators.  I was looking for something useful in itertools but I couldn't find anything obviously useful. Might've missed it, though.  Related question:


Here is a proof of the sequence lemma I lifted from this . It seems to me naively that the axiom of choice is being used to selected the $x_n$'s. Is the axiom of choice being invoked in this argument? Is it necessary?  The top answer in this  says that we can choose some element from each set in a finite collection of non-empty subsets without choice, though I'm not sure how to do that rigorously. Could some inductive argument be used in the case above?

On  it is mentioned that "...  in order to prove that every accumulation point $x$ of a set $S\subseteq \mathbf R$ is the limit of some sequence of elements of $S\setminus \{x\}$, one uses (a weak form of) the axiom of countable choice. When formulated for accumulation points of arbitrary metric spaces, the statement becomes equivalent to $AC_\omega$. ..."  I have Herrlich's paper "Choice principles in elementary topology and analysis" where in theorem 2.4. it is stated that these are indeed equivalent. Then I looked up the reference he quotes, [4], which are Bentley H.L., Herrlich H., Countable choice and pseudometric spaces which does not contain the proof and  does also not contain the proof, hence my question:   Where can I see a proof of      "if $S$ is a set in a metric space $X$ with accumulation point $s$   then there exists a sequence $s_n$ in $S$ converging to $s$"   $\implies$ $AC_\omega$   ? (the other implication is clear to me). Thanks.


I am new to pygame and am creating a small game in which players can push each other to go outside the given arena to score points. I have a problem in detecting when characters run in to each other. I have a player sprite and enemy sprite to detect collision (pygame.sprite.spritecollide), but to take any action after that is very tricky and am not able to cover all the possible cases. In most of the examples, it is always an immovable object (wall/maze/tanker etc) on the other end and so it is relatively easy to implement. But, with both characters moving, I am unable to calculate exactly and deal with this. Also, my characters just shouldn't run in to each other but can be close enough - because they'll have to be able to push each other. Can anyone give pointers to implement this.

Let's assume I'm using this character.  (source: ) How would you implement collision detection for it? Using a bounding box doesn't seem to be a good approximation, because the bird's shape is nowhere near a square. I was thinking of having a sort of quad tree data structure inside the object that represents portions of the image. Each leaf could be either false (in case it covers the white/transparent space outside the bird) or true (in case it represents an area of the bird i.e. beak, eye etc). Then somehow test the only obstacle in the scene for collision with the bird. But my problems in my approach are:  I don't know how to initialize the quad tree. Once the quad tree is initialized, I'm not sure how to traverse & use it once the obstacle is within the coordinates of the image.  How would you do collision detection with non-squarish characters? LE: The other approach I've seen was to use multiple bounding boxes. For example I'd have one or a few bounding boxes for the beak, then a few of them for the hair or the tail. But it can get tedious. If this is a valid approach in my case, how would I generate those bounding boxes? I doubt I'd have to have them hardcoded in my program. LE2: I care about fairly precise collisions. I can't imagine how a single bounding box or circle can at least approximate decently that shape, so this approach won't work.


I just want to ask a simple question  I created a list of list and want to change one value in the list by index it:  A = [[0] * 3] * 3 print A, A[0][0] A[0][0] = 34343 print A  The result is: [[0, 0, 0], [0, 0, 0], [0, 0, 0]] 0 [[34343, 0, 0], [34343, 0, 0], [34343, 0, 0]]   Why this happens?Where am I wrong?

I needed to create a list of lists in Python, so I typed the following: my_list = [[1] * 4] * 3  The list looked like this: [[1, 1, 1, 1], [1, 1, 1, 1], [1, 1, 1, 1]]    Then I changed one of the innermost values: my_list[0][0] = 5  Now my list looks like this: [[5, 1, 1, 1], [5, 1, 1, 1], [5, 1, 1, 1]]    which is not what I wanted or expected. Can someone please explain what's going on, and how to get around it?


I am an electronics beginner and I created a small little circuit, just a battery a resistor and a led, then to ground. This is the circuit:         – Schematic created using   Now I have a few questions about it. I know voltage is the different of electrical charge between two points, so I measured that difference:  Point A to B: 3.27V Point B to C: 1.82V   First question: Does that mean that the actual voltage of: Point A: 5V Point B: 1.73V Point C: 0V?   So I am not sure if my calculations of voltage are correct. I also have this other questions:   Does the resistor have to be before the component I am trying to protect, like an LED. I have seen people place it after, but wouldn't that give a full 5V to the led or component? Ground has a neutral charge right? so why do electrons want to travel so badly to a point that has no electric charge?   Thank you

Note: I am very new to the more advanced side of electricity. I do not have a firm grasp on the exact mechanics.  Lets say I have an example circuit:  5V Power Supply -> LED -> Resistor -> Ground  Now the LED is receiving 20ma and 5V. If I were to switch the LED and the resistor however, the LED should receive less voltage but the same current, so wouldn't it be dimmer? Or would it receive the same voltage?  I've looked at these two threads and their answer doesn't help.


Currently looking for ideas on how to handle sandbox refreshes, where production and the sandboxes use different configurations in a Connected App. That is, each environment has a Connected App where a different certificate and URL is used. Is there an easy way to handle this without manually re-setting up Connected Apps when doing refreshes? It seems the only possible way to automate this would be with the sfdx force:mdapi since unlocked packages can't be used with Connected Apps. I wanted to check if this is actually the recommended method though as it doesn't seem great. Any guidance is appreciated. Thanks.

I am trying to dynamically update the callback url in a connected app.   When creating a sandbox, I want to run an apex class that change the callback URL from a production to UAT callback endpoint.   I am assuming that I would place this in the implements SandboxPostCopy apex class where I am updating other custom settings to point to lower environments when the sandbox is done copying.   Is there anyway to have the Callback URL in a connected app be dynamic by referencing a custom setting with {!$Setup.myCustomerSetting__c.activeCallBackUrl__c}? Is there any other way to do this dynamically?


How do I permanently turn on line numbers in IntelliJ IDEA 14?  This post is outdated:

How can I permanently enable line numbers in IntelliJ IDEA?


Does either the single quote (') or double quote (") have a function where they will parse through the string and replace variables with values? I remember that in PHP the parsing engine will parse through the string and automatically switch out any variables with their values (I don't remember which actually has that effect off the top of my head) so you don't have to type "somestring" + aVariableusing the concatenation  operator. in what I have read through so far on  I haven't been able to find anything about it. Also unless I missed it the post  does not directly cover this information.

console.log("double"); vs. console.log('single'); I see more and more JavaScript libraries out there using single quotes when handling strings. What are the reasons to use one over the other? I thought they're pretty much interchangeable.


If I have a command which wants to write to a file, can I somehow redirect this output to the console? For example: clang-tidy-diff.py --export-fixes FILE and I would really just like to read the output in place.

Similar problem as here  However, the solution given there is not universal.  My problem: I have a command that produces output to STDOUT. At the same time, I can specify via arguments to produce another output that goes straight to a file.  tcsh$ hmmscan --domtblout FILEOUTPUT Pfam-A.hmm query.fasta   Pfam-A.hmm is a database file (input); query.fasta is also an input file  How can I redirect FILEOUTPUT to STDOUT ?  Background: I plan to use the command on thousands of inputs and I need to run it for each of them separately. The command is called within a Python script, and I would like to read its FILEOUTPUT directly into the memory/a variable using the subprocess module. I know how to get the STDOUT with the subprocess module; so if I could redirect FILEOUTPUT to STDOUT...  I tried already stuff like this (ended up with errors or created files):  tcsh$ hmmscan --domtblout >/dev/tty Pfam-A.hmm query.fasta tcsh$ hmmscan --domtblout >(mypipe) Pfam-A.hmm query.fasta tcsh$ hmmscan --domtblout >$ Pfam-A.hmm query.fasta tcsh$ hmmscan --domtblout >($1) Pfam-A.hmm query.fasta tcsh$ hmmscan --domtblout >cat Pfam-A.hmm query.fasta tcsh$ hmmscan --domtblout test.tab Pfam-A.hmm query.fasta >/dev/tty


I logged into google hangouts at my mothers house, on her tablet, through her wifi. How can google give a address to a house eight miles away?

I have a major problem that I hope someone can help with. On my Google Maps feature under my Location History it shows a location that I was never at at any point, but when my wife happened to see that location she doesn't believe me that the GPS could be wrong and pinpoint that location if I was never there.  I was first wondering myself how could that could be possible if I was never there or my phone was never at that location that was 35 miles away from me and second is there any way I could prove the GPS being wrong? Can I contact Google Maps and can they give an official printout of that certain day and every location I was? I really need to prove my honesty to her and hope there is a way.


I have a newbie question about focal length, what it actually means for lenses and how I can translate this into "how close to the target it's going to practically take me" (I don't want to use the term zoom here to avoid confusion, perhaps magnifying power is what describes best what I'm after, basically shots from the distance, not macro).  Here's an example: I currently have a Sigma 18-200mm lens (therefore approx. 11x zoom), which I use with Canon EOS 400D and also a compact Sony Cyber-Shot DSC-HX60 with focal length 4.3-129mm (approx. 30x zoom). Even though 200mm is obviously more than 129mm the Sony camera takes me closer to the target. Looking at zoom factor (30x comparing to 11x) this may seem obvious, but it's less obvious when you compare it to other lenses, e.g. 200-500mm lens, which effectively has "only" 2.5x zoom, but actually takes me closer to the target.  How can I make sense of this when looking at other lenses? For example let's consider Tamron 16-300mm, its zoom is obviously approx. 20x, but how can I compare it to Sigma 18-200mm or Cyber-Shot 4.3-129mm? Is it going to take me closer to the target, e.g. magnify objects better then both of them or only better than Sigma, but still not as good as Sony? (ignoring quality of picture of course)

Zoom lenses and cameras with superzooms are often sold with a times ("×") zoom number — like a 12x zoom or 30x zoom. The question  explains how this relates to focal length numbers, like 70-200mm or 18-55mm. But how does ×-zoom relate to magnification, when used for macro or just to make something far away look bigger?  How can two 70-200mm lenses have different magnification?


I have a class dedicated to managing sharedpreferences, however I keep getting a NPE on one of my calls. Heres the class,  public class UserManager extends Activity{  Context mContext;  UserManager(Context mContext){     this.mContext = mContext; }   public boolean getFromMatches(String userUid, String matchUid){     SharedPreferences spMatches = mContext.getSharedPreferences(getString(R.string.match_key), Context.MODE_PRIVATE);     if(spMatches.contains(userUid + matchUid)){         return true;     }else{         return false;     } }   }  This is what is passed from my main activity:      @Override protected void onCreate(Bundle savedInstanceState) {     super.onCreate(savedInstanceState);     setContentView(R.layout.activity_main_screen);      userManager = new UserManager(getApplicationContext()); }   The NPE is received at this line:  SharedPreferences spMatches = mContext.getSharedPreferences(getString(R.string.match_key), Context.MODE_PRIVATE);

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?


What is the PDF of $Z=\sqrt{(X-x_0)^2+(Y-y_0)^2}$ when $X$ and $Y$ are i.i.d. normal random variables with zero mean, i.e., $X \sim N(0,\sigma^2)$ and $Y\sim N(0,\sigma^2)$?

Assume you are given two objects whose exact locations are unknown, but are distributed according to normal distributions with known parameters (e.g. $a \sim N(m, s)$ and $b \sim N(v, t))$. We can assume these are both bivariate normals, such that the positions are described by a distribution over $(x,y)$ coordinates (i.e. $m$ and $v$ are vectors containing the expected $(x,y)$ coordinates for $a$ and $b$ respectively). We will also assume the objects are independent.  Does anyone know if the distribution of the squared Euclidean distance between these two objects is a known parametric distribution? Or how to derive the PDF / CDF for this function analytically?


The man command brings up a nice manual for many programs, but how can I use it more effectively? For example man gcc brings:  NAME        gcc - GNU project C and C++ compiler  SYNOPSIS        gcc [-c|-S|-E] [-std=standard]            [-g] [-pg] [-Olevel]            [-Wwarn...] [-Wpedantic]            [-Idir...] [-Ldir...]            [-Dmacro[=defn]...] [-Umacro]            [-foption...] [-mmachine-option...]            [-o outfile] [@file] infile...         Only the most useful options are listed here; see below for the        remainder.  g++ accepts mostly the same options as gcc. .... many text   But what if I need only some part of it? What is the best way to jump to the section where -Idir is described, for example?

Is there a option to search within manpages?


I have a code that first receives an input from the user and then counts how many " ) " and " ( " there are in the input:  Scanner in = new Scanner(System.in); String input = in.next(); String[] array = input.split(""); int countS = 0; int countH = 0;     for(int i = 0; i < input.length(); i++){     if(array[i] == ")"){         countH ++;     }     else if(array[i] == "("){         countS ++;     } } System.out.println(countH); System.out.println(countS);   I what to know what's wrong with the program. All help is appreciated!

I've been using the == operator in my program to compare all my strings so far. However, I ran into a bug, changed one of them into .equals() instead, and it fixed the bug.  Is == bad? When should it and should it not be used? What's the difference?


Is there a way in gcc/g++ 4.* to write a macro that expands into several lines?  The following code:  #define A X \ Y   Expands into  X Y   I need a macro expanding into  X Y

How do I write a cpp macro which expands to include newlines?


I would like to color the entire citation. I am working with this citation style, using biblatex: Author Year. Hyperref is only coloring the year.   Also, I would like Year to be in parentheses.  \documentclass{article} \usepackage{times} \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} \usepackage{lmodern} \usepackage[style=authoryear,sorting=nyt,backend=bibtex,url=false,maxcitenames=1,doi=false,isbn=false,url=false]{biblatex} \usepackage[expansion=alltext,stretch=30]{microtype} \usepackage[colorlinks,citecolor=blue,pdftex,urlcolor=blue]{hyperref}  \addbibresource{tesis.bib}  \begin{document}   Thanks in advance,  Joaquín

I'm new here so I'm not sure if this is the right way to express my question:  I'm using the excellent biblatex package with the author-year style and want the links in my citations to include the name of the author as well as the parentheses. The answer presented at  did exactly what I wanted but it seems the solution is broken with the newest biblatex version 1.4b. Can anyone help me by adapting the code to the newest biblatex version?


Find all natural numbers $n$ such that $2^n$ divides $3^n -1$   I think that the only solutions are $n = 0,1,2,4$, but I have no idea on how to prove it.  I tried to write $3^n-1$ as $1+3+3^2+...+3^{n-1}$ and manipulate the sum but found my self at the equally hard problem of finding the power of two dividing $3^k+1$

The title says it all. For what natural numbers $n$ does $2^n$ divide $3^n - 1$? By substituting values I can see that this happens for $n = 1, 2, 4$ but are there more? I am not able to prove/disprove.


Can i get mobile number of iphone using ios sdk. I have found some CTCarrier but i could not get phone number of sim card.  I found some conversation in stack that it is not possible. Is that correct ?  Plz help

Is there any way to get own phone number by standard APIs from iPhone SDK?


Is it possible to get admitted in a phd in computer science with an undergraduate degree in electrical engineering? If the answer is yes, then would a graduate student in theoretical computer science who has an undergraduate degree in electrical engineering experience difficulty understanding the computer science?

Can I be admitted to graduate school in a different field from my degree?  Specific cases include:   If I've taken plenty of advanced courses in field X in the process of completing a degree in another field, can I apply to graduate school in X? What if I haven't taken many courses in X, but I have acquired a good grasp of X through self-study or working in a related field? What if I've never studied X, but I have done very well in an unrelated field?  Could I be admitted to graduate school in X on the basis of general intellectual promise, and then make up the missing background after enrollment?   Note that this question is an attempt to provide a comprehensive answer, to avoid the need for a profusion of field-specific questions on this topic (see the associated ). Please feel free to edit the question or answer to improve them.


ubuntu is not getting updated when i try to update it shows:  E:Malformed line 43 in source list /etc/apt/sources.list (dist parse)   My update manager is also not working when i try to open it from terminal it also show some errors similar to this

I have unistalled and reinstalled the Ubuntu Software Center as per info I found in a similar thread and I got the same response about line 91 or something like that.  I just tried to upload a screen shot but since I'm new it won't allow me to.  I also can not figure out how to cut and paste anything so I have to hand type what the error screen says, both when I attempt to open the software center and nothing happens, when I try to enter commands into the terminal to uninstall, reinstall, whatever I get the same following:  COULD NOT INTITIALIZE THE PACKAGE INFORMATION An unresolvable problem occured while initializing the package information Please report t:his bug against the 'update-manager' package and include the following error message: 'E: Malformed line 91 in source list/etc/apt/sources.list (dist parse)  E: The list of sources could not be read.,  E: The package list of status file could not be parsed or opened.   How do I report bugs?  What can be done about this.  I have searched and everything everyone says to do leads me back to the same line error message.  So, I don't know how to get to line 91 in the source list; to tell you what it says. Sorry, I'm really new to this. That is what I need is to find out how to get there and fix what it says. I would really like to NOT have to re partition my hard drive and start from scratch, so I'm really looking forward to getting this problem solved. I need to be able to install new software.


I am using Unity to attempt to have missile A launch at incoming missile B and blow it up. However in order to do this accurately, A must be able to take into account B's current velocity, direction and distance in order to calculate where it needs to aim in order to succesfully hit it. How do we go about this using the below as an example?

I am developing a 2D Android game and I am making an aiming algorithm for AI projectiles to hit enemies either following a path, or free moving. At the moment it just calculates where the target will be after a distance and fires a projectile to meet it at that distance. Of course this means varying the projectile speed to meet the target.  Does anyone have any tips for a simple-ish algorithm (optimal-ish) to calculate when the projectile needs to fire and where it needs to aim if it can only travel at a constant velocity? Say the projectile goes twice the speed of the target?  The only way I can think of involves searching and seems quite large.


Evaluate the integral $$\int\frac{e^x.(2-x^2)}{(1-x)\sqrt{1-x^2}}dx$$   Set $u=\dfrac{1}{\sqrt{1-x}}\implies du=\dfrac{-dx}{2(1-x)^{3/2}}$ $$ \int\frac{e^x.(2-x^2)}{(1-x)\sqrt{1-x^2}}dx=\int\frac{e^x.(2-x^2)}{(1-x)^{3/2}\sqrt{1+x}}dx=\int\frac{e^x{2-x^2}.-2du}{\sqrt{\dfrac{2t^2-1}{t^2}}}dx $$ I have no clue about what is the easiest substitution possible inorder to solve the above integral ?  I tried $u=\dfrac{1}{\sqrt{1-x}}$ yet it is becoming more cumbersome I guess.

So, the question says I have to perform the indefinite integration $$\int\frac{e^x(2-x^2)}{(1-x)\sqrt{1-x^2}}dx$$ I know that $$\int e^x(f(x)+f'(x))dx=e^xf(x)+C$$ Since any other substitution (using $x=ln(t)$ etc.) doesn't work, I expect I have to break the fraction with $e^x$ in the above integral to make separate fractions for $f(x)$ and $f'(x)$ somehow. I separate $2-x^2=1+(1-x^2)$, but that doesn't work (leaves $x$ in the numerator of derivative which I don't see in the question). Any other tricks?


In Monolith Arena, :  after the tiles have been drawn, the player must DISCARD ONE OF THE THREE TILES into the discard pile.  This is during the player upkeep step, so the sequence of events:  Draw three tiles Discard one tile Consider the remaining tiles and potentially play them  Is it against the rules to retract the discarded tile or change your mind, directly after discarding it, without input from the other player(s)? Asking for a friend.

A generic question across most board games: once a player has taken their turn (taken their finger off the piece they are playing), should they be allowed to change their mind?  Similarly, if a player forgets to take a privilege, such as an occupied building in Puerto Rico giving an extra worker, or plantation, if they remember a few moves later, should they be allowed to take the privilege?  Very few rules explicitly express how these events should be dealt with, so they are generally left up to the group. However, my group's rules will change depending on the personality of the players playing (not all members are available each time we play). I would like to make this consistent, and would appreciate feedback on how others deal with this scenario.


I am working on a live wallpaper with Libgdx .  I am wondering if I can give neon glow to my textures , at runtime .  Is this possible? If yes can anybody give me any pointers?

I've recently implemented a glow effect using a gaussian filter and could not get the full effect I was wanting. I'm curious to know if how certain glow effects are done in WoW. Like this image:  Around the sword is a really nice glow effect. How might this be done? Also, sometimes in WoW you see these glow effects take a life of there own. Like the purple glow in this pic:  Are these accomplished with particle effects? Are there any good resources/tutorials that could help with someone to learn how to do these effects?


I feel like I constantly get notifications from the Mac App Store. I find this distracting and stressful and would like to change how often the Mac App Store checks for updates, or how often it notifies me of these updates.   I know I can go into System Preferences and disable the automatic checking for updates, but I don’t want to do this as I’m not likely to remember to manually check for updates myself.  Is it possible to check for updates less often or to get notified less?

Similar to   Is there a way to change the frequency the App Store checks for updates in Yosemite?


I have a footer at the bottom of my page. When there is enough content the footer is pushed of the page until you scroll down where it becomes visible. This is good but when there is not enough content on the page the footer is visible without scrolling somewhere on the page but it is not at the bottom where it should be. How can I make my footer be at the bottom of the page when there is not enough content? Here is my code:           <title>Omicrome</title>    //stuff
               //stuff                   //stuff

                About          Privacy Policy         Contact

    My css:  body{      background-image: url("../img/bg.jpg");      background-repeat: repeat;  } header{     overflow: hidden;  } .container_24{      margin-left: auto;     margin-right: auto;   } #rectangle {     float:bottom;     position: relative;     width: 100%;     height: 40px;     padding-top: 15px;     padding-bottom: 10px;     background: #404040;     top: 50%;  }

I have the following page (deadlink: http://www.workingstorage.com/Sample.htm ) that has a footer which I can't make sit at the bottom of the page. I want the footer to  stick to the window bottom when the page is short and the screen is not filled, and stay at the document end and move down as normal when there is more than a screenful of content (instead of overlapping the content).  The CSS is inherited and befuddles me. I can't seem to change it properly to put a minimum height on the content or make the footer go to the bottom.


I came to know about two definitions of a subbasis of a topology.   A collection of subsets of $X$ viz. $S$ is said to be a subbasis of a topology $T$ on $X$ if $S$ covers $X$ and the finite intersections of elements of the subbasis form the basis elements (H.L.Royden). If we consider the all the topologies on $X$ containing $S$, then their intersection is also a topology on $X$ and it is the smallest topology containing $S$. Then $S$ is said to be a subbasis of the smallest topology, and the topology is said to be generated by $S$.   Now I want to prove their equivalency, i.e. $S$ is a subbasis of a topology $T$ iff $T$ is generated by $S$. I have tried in the way:  First let $T$ is generated by $S$. Then by $2^{nd}$ definition $T$ is a topology containing $S$. Let $B$ be the set of all finite intersections of elements of $S$.Then $S$ is a subset of $B$ and $B$ is a subset of $T$ (as $T$ is a topology). LET $T_1$  be the collection of possible unions of elements of $B$, we will show that $T = T_1$  After this I am not able to proceed. Also I am unable to sketch the converse part. If something is wrong, please let me know, and also I hope to get help. Thank You.

I came to know about 2 definitions of a subbasis of a topology. 1. A collection of subsets of X viz. S is said to be a subbasis of a topology T on X if S covers X and the finite intersections of elements of the subbasis form the basis elements (H.L.Royden). 2. If we consider the all the topologies on X containing S, then their intersection is also a topology on X and it is the smallest topology containing S. Then S is said to be a subbasis of the smallest topology, and the topology is said to be generated by S.  Now I want to prove their equivalency, i.e. S is a subbasis of a topology T iff T is generated by S. I have tried in the way: First let T is generated by S. Then by 2nd definition T is a topology containing S. Let B be the set of all finite intersections of elements of S.Then S is a subset of B and B is a subset of T (as T is a topology). LET T1 be the collection of possible unions of elements of B, we will show that T = T1. After this I am not able to proceed. Also I am unable to sketch the converse part. If something is wrong, please let me know, and also I hope to get help. Thank You.


I'm trying to fetch data using importxml() but it just fails with "#N/A".  I have tried it on other pages and works fine.  But it doesn't work on this site, and I don't know why. Here is the formula that doesn't work: =importxml("http://www.aastocks.com/en/stocks/quote/quick-quote.aspx?symbol=00027","//*[@id='tbQuote']/tbody/tr[1]/td[2]/div[2]/span/span/text()") Ultimately I'm trying to fetch the "price change" (Chg), and "price change (%)" (Chg(%)) elements, but all fail. What can I do to fetch these two pieces of data?  Thanks a lot!

Google Sheets has several import functions   IMPORTDATA IMPORTFEED IMPORTHTML IMPORTXML   Sometimes the above functions returns errors like #N/A Imported content is empty and would like to be sure that there isn't a problem with the resource content to be imported.  How do I know if these functions are able to get the content that I looking to import?  I know that there also exist IMPORTRANGE but that function only is able to import content from Google Sheets spreadsheets


I'm trying to separate a specific area of lines in a topo shapefile in Qgis so I can import it into Civil 3D without it taking several centuries to load in the full file, however when I use the "split features" tool it takes forever just to cut one line, and trying to cut multiple lines just generates an error.  Also, since it's hard to explain what exactly I'm trying to do in a few words: just imagine having a square polygon and cutting out a smaller square from the center and deleting the rest (but in this sentence replace "square" with "topo line data").

I have a line layer and a polygon layer. Both files have the same SRS. I want in a new shape file only the lines covered by the polygons.   I tried in QGIS the Vector -> Geoprocessing -> Clip tool but I only get an empty shapefile.  How do I do this with QGIS?


So, I was given the task of writing two simple methods for an array: the first method, double the size of the array; the second method, find the index of the first duplicate string in the array. The main method was written by my professor and is not to be altered. My problem is that I continue to get a NullPointerException when running my code. I believe it has to do with Arrays.sort() or my teacher's code in main, but I was instructed to: only use arrays (no other data structure), use Arrays.sort() in finding the index of the dupe, and not to modify anything else in the program...is there any way I can rewrite my methods keeping to these instructions?   Full code:  import java.io.*; import java.util.*;  public class Practice {     static final int CAPACITY = 10;     static final int NOT_FOUND = -1;     public static void main (String[] args) throws Exception     {         if (args.length < 1 )         {             System.out.println("\nusage: C:\\> java Practice <words filename>\n\n"); // i.e. C:\> java Lab2 10Kints.txt 172822words.txt             System.exit(0);         }       String[] wordList = new String[CAPACITY];     int wordCount = 0;     BufferedReader wordFile = new BufferedReader( new FileReader(args[0]) );      while ( wordFile.ready() ) // i.e. while there is another line (word) in the file     {   if ( wordCount == wordList.length )              wordList = upSizeArr( wordList );         wordList[wordCount++] = wordFile.readLine();     } //END WHILE wordFile     wordFile.close();      System.out.format( "%s loaded into word array. size=%d, count=%d\n",args[0],wordList.length,wordCount );     int dupeIndex = indexOfFirstDupe( wordList, wordCount );     if ( dupeIndex == NOT_FOUND )         System.out.format("No duplicate values found in wordList\n");     else         System.out.format("First duplicate value in wordList found at index %d\n",dupeIndex);  } // END OF MAIN  // TWO METHODS   static String[] upSizeArr( String[] fullArr ) {      int size = fullArr.length; //find the length of the arrays     String[] newSizeArr = new String[(2 * size)]; // creates new array, doubled in size     for (int a = 0; a < size; a++) {         newSizeArr[a] = fullArr[a];     }     return newSizeArr;  } static int indexOfFirstDupe( String[] arr, int count ) {            Arrays.sort(arr);     int size = arr.length;     int index = NOT_FOUND;      for (int x = 0; x < size; x++) {         for (int y = x + 1; y < size; y++) {             if (arr[x].equals(arr[y])) {                 index = x;                 break;             }         }     }     return index; } } // END OF PROGRAM   Location of the NullPointerException:    Edit: This question addresses an NPE in library code, not my own code.

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?


I don't get it how calculate $\langle2,x\rangle$. I need that because I want to use that these ideals cannot be generated by one single element. And concludes that $\mathbb{Z}[x]$ is not a PID.

Hi I don't know how to show that $\langle 2,x \rangle$ is not principal and the definition of a principal ideal is unclear to me. I need help on this, please.   The ring that I am talking about is $\mathbb{Z}[x]$ so $\langle 2,x \rangle$ refers to $2g(x) + xf(x)$ where $g(x)$, $f(x)$ belongs to $\mathbb{Z}[x]$.


I am fairly new to c++ and have not had much experience with headers or templates, and I have not had any experience with them combined.  So, I have run into problems trying to use the class I have created.  My class definitions and headers are as follows: J.h is the header file for the template class J.  #ifndef J_H #define J_H  template<class t> class J {         public:                 void speak(); };  #endif   J.cpp has the function definitions for it's header.  #include "J.h" #include <iostream>  template<class T> void J<T>::speak(){         std::cout << "Hello from j"; }   main.cpp has the main function and tries to use J.  #include "J.h"  int main(){         J<int> j;         j.speak(); }   My problem is that when I compile with g++ J.h J.cpp main.cpp, I get the error undefined reference to J<int>::speak(), but doing g++ J.h J.cpp runs without any error.  I am very new to templates, so any help is appreciated.  Thank you in advance.

Quote from :     The only portable way of using templates at the moment is to implement them in header files by using inline functions.   Why is this?  (Clarification: header files are not the only portable solution. But they are the most convenient portable solution.)


I'm stuck at a particular exercise in a textbook and would appreciate any help. The statement goes as follows: Let f and g be continuous on $\mathbb{R}$ to $\mathbb{R}$. Is it true that $f(x)=g(x)$ for x $\in \mathbb{R}$ if and only if $f(y)=g(y)$ for all rations numbers y in $\mathbb{R}$?

Akhil showed that the  is the same as the continuum, using as a step the observation that continuous functions that agree at rational points must agree everywhere, since the rationals are dense in the reals.  This isn't an obvious step, so why is it true?


I'm using the  algpseudocode package, and have defined a procedure inside an algorithmic environment that I would like to refer to from the main text.  Inside this environment,  \Procedure{MyProc}{$x$}   and  \Call{MyProc}{$y$}   both display MyProc in what appears to be a nice small-caps style.  I would like this same styling to be applied when I refer to the procedure name from the main text, but I couldn't find a way to do this in , and trying to start an "in-line" environment didn't work:  Calling the procedure\begin{algorithmic}\Call{MyProc}{$y$}\end{algorithmic} results in   It results in the error:  ! LaTeX Error: Something's wrong--perhaps a missing \item.  See the LaTeX manual or LaTeX Companion for explanation. Type  H <return>  for immediate help.  ... l.418 ...thmic}\Call{MyProc}{$y$}\end{algorithmic}                                                   , results in ?   Any ideas?  Please don't tell me I have to grovel through the algpseudocode source code, dig up whatever style it's applying, and hardcode that each time I want to refer to a procedure name...  Thanks!

Given an algorithm written in algpseudocode:  \documentclass{article} \usepackage{algorithm} \usepackage{algpseudocode} \begin{document} \begin{algorithm}   \caption{Part 1}   \begin{algorithmic}[1]     \Procedure {FooProc}{$G$}       \State ...     \EndProcedure   \end{algorithmic} \end{algorithm} \end{document}   How can I now refer to FooProc in my document (outside of the algorithm environment) such that it has the same typeset as in inside the algorithm environment?


I have to prove that $S=\{a+b\sqrt{2} \mid a,b \in \mathbb Q\}$ is a field and so far everything worked out for me except for finding the multiplicative inverse over $(S\backslash\{0\}, \cdot)$ which is: $$\forall a \in S: \exists (a^{-1}) \in S: a\cdot(a^{-1})=1$$  As a proof I thought of: $(a+b\sqrt{2}) \cdot (a+b\sqrt{2})^{-1} \Rightarrow (a+b\sqrt{2}) \cdot \frac{1}{(a+b\sqrt{2})}$ but I am stuck with the fraction. It is non-trivial for me to compute the inverse of an element $a \in S$.  Any help is highly appreciated! Thank you!

Let $\mathbb{Q}(\sqrt{d}) = \{a + b \sqrt{d}: a,b \in \mathbb{Q} \}.$ Show that $\mathbb{Q}(\sqrt{d})$ is a field.    Everything seems obvious except for existence of inverses in the multiplicative group of $\mathbb{Q}(\sqrt{d}).$  Suppose $\alpha \in \mathbb{Q}(\sqrt{d}) \Longrightarrow \alpha = a + b \sqrt{d}.$ To prove that $\mathbb{Q}(\sqrt{d})$ contains multiplicative inverses, observe that for a non-square $d$ and $a - b\sqrt{d} \ne 0$  one has $$\frac{1}{\alpha} = \frac{1}{a+b\sqrt{d}} \cdot \frac{a - b \sqrt{d}}{a - b \sqrt{d}} = \frac{a}{a^2-b^2d}- \frac{b}{a^2-b^2d} \sqrt{d}.$$  If $a,b \in \mathbb{Q} \Longrightarrow a^2,b^2 \in \mathbb{Q} \Longrightarrow b^2 d \in \mathbb{Q}$ (since $d \in \mathbb{Z}$) $\Longrightarrow a^2-b^2d \in \mathbb{Q} \Longrightarrow \frac{a}{a^2-b^2d}, \frac{b}{a^2-b^2d} \in \mathbb{Q}.$ Hence $\frac{1}{\alpha} \in \mathbb{Q}(\sqrt{d}).$   Is this correct?


Many top universities in north America accept international ph.d. students and pay their tuitions, insurnace and other funds. To get visa, international students should convince the officer that they will go back to their home countries. I am wondering why universities should accept international students and what are the benefits for universities and the destionation universities?

I would like to understand positive and negative effects for a host country and for a home country of a student.


For a project I am working on, I need some kind of way for a micro-controller (preferably Arduino, since I have background knowledge) to identify a certain symbol on a piece of paper (e.g. recognising an ampersand drawing), and then run some code depending on what it sees. The more symbols it could recognise, the better.    I understand that for identifying pictures in almost any program, you need a database to refer to. I assume this wouldn't be too difficult, but some tips on managing a database would be appreciated.    If there aren't any simple Arduino programs that exist, I could work with a pre-existing IC built for this purpose (I don't know if that would make sense, but just throwing ideas around). A link to a datasheet would also be appreciated.

Is it possible to do image processing (to extract numbers and text) using a microcontroller? If not, what are the alternatives to do this task?


I have searched but could not fond an answer.  So i have   Mood = raw_input("How are you?")   How do I make it so it picks the raw question from a list so it could be 'how are you' are 'what are you feeling'

Assume I have the following list:  foo = ['a', 'b', 'c', 'd', 'e']   What is the simplest way to retrieve an item at random from this list?


I only know the code in which accumulator contents are affected. It is not a duplicate as I have asked for a solution which doesn't affect accumulator.

My Microprocessor teacher of 8085 gave an assignment to set all flags ! I have written this little program to set all except Sign, Please help me out   MVI A,0FFH  ANI 01H  HLT


+----+---------------+-------+---------------+ | id |     name      | phone |    ip_addr    | +----+---------------+-------+---------------+ |  1 | customname001 |  1234 | 192.168.100.1 | |  2 | customname002 |  2156 | 192.168.100.2 | |  3 | customname003 |  9685 | 192.168.100.3 | |  4 | customname004 |  1546 | 192.168.100.1 | |  5 | customname005 |  1234 | 192.168.100.1 | +----+---------------+-------+---------------+   In my codeigniter project I am trying to build a model which will help me insert a new row into a table which looks something like the above one. The condition I want to apply here is to check if the combination of name, phone and ip_addr is unique or not.  I know that for a single column if we set the value to be unique then the values can't be repeated but my example is a different case where I want the combination of all the columns(except the id) to be unique.  Can anyone help me here in building the model which will help me to add new pair of name, phone and ip_addr and check if the pair already exists and accordingly give a feedback.

I have a table:  table votes (     id,     user,     email,     address,     primary key(id), );   Now I want to make the columns user, email, address unique (together).  How do I do this in MySql?  Of course the example is just... an example. So please don't worry about the semantics.


After SQLServer 2016SP1 installation, installation of ODBC Driver 13.1 resolves problem to start SQLAgent and to read Errorlog in SSMS.  However, another connection exists for .NET connection. The following connection string does not work :  $Connection = New-Object System.Data.SQLClient.SQLConnection    $Connection.ConnectionString = "server=SERVER\INSTANCE;Database=master;..."    $Connection.Open()    Connection.close()   The error message is:     A network-related or instance-specific error occurred while establishing a connection to SQL Server. ...   What is a solution or workaround to this issue?

I have SQL Server 2005 which is installed on server machine.  I was working fine on SQL server before I change the server machine IP. I changed server machine IP to host the Web Service on it.  But now when I enter the Login and Password information SQL Server displays this error message:     A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server) (Microsoft SQL Server, Error: 2)   I also tried to remove Server machine IP, Still I can't able to access the SQL Server. My all database stucked in it. Or can I recover my SQL server database?


I am testing out maven and its capabilities. I am trying to write a string to a text file using commons-io    import org.apache.commons.io.FileUtils; ... public void writeToFile(String fileName){     File file = new File(fileName);     ...     FileUtils.writeStringToFile(file,rowEntry); //rowEntry is a String }     I have added the commons-io to the dependencies    POM.xml    <dependency>     <groupId>commons-io</groupId>     <artifactId>commons-io</artifactId>     <version>2.5</version>  </dependency>     It compiles but it throws an exception when I run it  Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/commons/io/FileUtils at com.RandCollections.StringFinder.writeToFile(StringFinder.java:704) at com.RandCollections.StringFinder.menu(StringFinder.java:123) at com.RandCollections.StringFinderMain.main(StringFinderMain.java:28) Caused by: java.lang.ClassNotFoundException: org.apache.commons.io.FileUtils at java.net.URLClassLoader.findClass(URLClassLoader.java:381) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) ... 3 more      I think Im missing out on some things, can you help point it out please?

I am getting a NoClassDefFoundError when I run my Java application.  What is typically the cause of this?


I'd like to trim left/right the input_string before passing it to regex_match in the if statement and I've unsuccessfully tried the , not sure how to solve it though.  How do I simply trim the inputs so that the first two inputs "  0  " and "  0.1  " would become valid numbers?  #include <string> #include <boost/algorithm/string.hpp>  #include <iostream> #include <regex> #include <vector> using namespace std;  int main() {     vector<string> string_vector = {"   0  ","   0.1   ","abc","1 a","2e10","-90e3","1e","e3","6e-1","99e2.5","53.5e93","--6","-+3","95a54e53"};      regex expression_two("^[+-]?(?:[0-9]*\\.[0-9]+|[0-9]+\\.[0-9]*|[0-9]+)[Ee][+-]?[0-9]+$|^[+-]?(?:[0-9]*\\.[0-9]+|[0-9]+\\.[0-9]*|[0-9]+)$|^[+-]?[0-9]+$");      for (const auto &input_string: string_vector) {         if (std::regex_match(input_string, expression_two))             cout << "[0-9] Char Class: '" << input_string << "' is a valid number." << endl;     }     return 0; }   Current Output  [0-9] Char Class: '2e10' is a valid number. [0-9] Char Class: '-90e3' is a valid number. [0-9] Char Class: '6e-1' is a valid number. [0-9] Char Class: '53.5e93' is a valid number.   Desired Output  [0-9] Char Class: '  0  ' is a valid number. [0-9] Char Class: '  0.1  ' is a valid number. [0-9] Char Class: '2e10' is a valid number. [0-9] Char Class: '-90e3' is a valid number. [0-9] Char Class: '6e-1' is a valid number. [0-9] Char Class: '53.5e93' is a valid number.

I'm currently using the following code to right-trim all the std::strings in my programs:  std::string s; s.erase(s.find_last_not_of(" \n\r\t")+1);   It works fine, but I wonder if there are some end-cases where it might fail?  Of course, answers with elegant alternatives and also left-trim solution are welcome.


I am unable to install wkhtmltopdf on Ubuntu 14.4. I downloaded from  Linux (Ubuntu Trusty) 64 bit. I ran the following command:  sudo dpkg -i wkhtmltox-0.12.2.1_linux-trusty-amd64.deb   Here's the log  (Reading database ... 61662 files and directories currently installed.) Preparing to unpack wkhtmltox-0.12.2.1_linux-trusty-amd64.deb ... Unpacking wkhtmltox (0.12.2.1) over (0.12.2.1) ... dpkg: dependency problems prevent configuration of wkhtmltox:  wkhtmltox depends on fontconfig; however:   Package fontconfig is not installed.  wkhtmltox depends on libjpeg-turbo8; however:   Package libjpeg-turbo8 is not installed.  wkhtmltox depends on xfonts-base; however:   Package xfonts-base is not installed.  wkhtmltox depends on xfonts-75dpi; however:   Package xfonts-75dpi is not installed.  dpkg: error processing package wkhtmltox (--install):  dependency problems - leaving unconfigured Processing triggers for man-db (2.6.7.1-1) ... Errors were encountered while processing:  wkhtmltox   I searched but could not find anything specific. What am I missing here?

Say, I have foo-1.2.3.deb which depends on perl and python, however, running command:  dpkg -i ./foo-1.2.3.deb   won't install these dependencies. So I must apt-get install perl python by hand.  How to make dpkg -i install these dependencies for me automatically?


I would like to know what would be the best way to check if a list is empty. I know this question seems silly, but I realize that sometimes when you are working with others and others read your code, using certain functions may look better than others, and would be more understandable for people coming from different programming languages. Say I have a list: names = ["Bob", "Billy", "Samuel", "Adam", "Rob"]  This is one way I can check if the list is empty: is_empty = bool(names)  This is another: is_empty = any(names)  I do realize the any function checks if there is at least 1 true value inside a list. What would be the best and quickest way to check if the list is empty? Which would look the best and in which scenarios? Are there any faster ways that I do not know of?

For example, if passed the following:  a = []   How do I check to see if a is empty?


1) I have lived here since 2006  2) I have been living here since 2006.   What's the difference between the above cases? Are there different conditions to use each one of them? Or can they be used interchangeably?  I have already read this answer but what I want is simple answer and explanation that whether I have lived here since 2006 mean I am not living here now or I am still living.No doubt this answer is well explained but I am unable to understand it completely that's why I said earlier that I want easy explanation. Hope you get my problem now.

What is the difference between the followings?  A. I have been living here for 5 years. B. I have lived here for 5 years.  Am I correct that these two represent the same event, but A emphasizes the continuity of living while B simply states a fact that you lived there from 5 years ago to the present? Is it true that the difference in present perfect and present perfect continuous is whether a speaker intends to emphasize continuity or a fact?


I am studying the ring theory and I got some point like $(2+3i)$ divides $(-1+5i)$ in the Eucledian domain $\mathbb{Z}[i]$. I do not know that how it can be possible. Please let me know about this.

Find the multiplicative inverse of $1+ 3\sqrt{2}$ in the ring $\mathbb{Q}(\sqrt{2})$ and use it to solve the equation $(1+3\sqrt{2})x=1-5\sqrt{2}$.  I think that the inverse is the conjugate, so it would be $1-3\sqrt{2}$, but then I don't know where to use in the equation that needs to be solved.


Should I write (n-1)th or (n-1)st Relatedly, is it "n minus oneth" or "n minus first".   Thanks!

Mathematicians commonly have to form ordinals from variables: you might look at the kth element of a sequence, for example. When the variable is a single letter, the ordinal is always formed with the suffix -th. Thanks to the unwritten conventions of variable naming, this usually results in one of the easily pronounceable words ith "eyeth" jth "jayth" kth "kayth" nth "enth" or mth "emth".  Things get a little bit trickier when you look at the elements near the kth one. Two opposing forces drag you in different directions when you try to form the ordinal for (k+1). On the one hand, orthographic consistency favours (k+1)th; on the other hand, "kay plus oneth" sounds less natural out loud than "kay plus first". In fact, I've caught one of my professors in a lecture saying (k+1)st at the exact same time as he was writing it on the board — as (k+1)th.  I think both variants are in use, and each has a defensible argument behind it, so I don't think one or the other is "correct". But I wonder if one gets used more than another. Ideally, I'd like to know     Between (k+1)th and (k+1)st, is one used more often than the other?   and better yet     Does usage differ based on context?    (I'm mainly curious about written vs spoken contexts, but I imagine it could be different based on discipline. Mathematicians can't be the only ones with this problem...)  Those are the questions I'd like to answer, anyways. I fear it might not be definitively answerable (although anecdotal evidence is still welcome!). My usual method — count the Google hits for each variant — is useless here because of the way Google handles punctuation. So, as a side note, I'd also love to hear answers to the more general question: How do I determine how widely used a term is when it consists mostly of punctuation?    EDIT (x2)   I thought I should clarify that the motivation for this question doesn't come from a particular instance I had in mind: I typically say (k+1)st out loud but might lean towards (k+1)th if I ever had to write it. I'm mostly curious about how they're used by others. I appreciate all the data points in your answers and the !  It seems that some of you have shared my Google troubles when trying to measure the relative usage of (k+1)st and (k+1)th. I realized that the underlying issue is applicable to more common usage problems, so I've spun the last part off as a separate question: see . Whoops, looks like that was a bit too meta as a separate question. So just keep in mind that Google page counts seem to be unreliable for this particular question unless you find a workaround to make it search for punctuation properly.  Anyone who can get some sort of tool to find hard data on this question gets an invisible second upvote from me and my eternal gratitude :)


I am trying to form functions from $[0,1)$ to different sets. first one was continuous surjection from $[0,1)$ to $R$. little modification of sinusoidal exponential function will satisfy the requirement. but for bijection from $[0,1)$ to $R$, I am not able to come up with any function. Is it possible? bijection doesn't have to be continuous.

How to define a bijection between $(0,1)$ and $(0,1]$?   Or any other open and closed intervals?   If the intervals are both open like $(-1,2)\text{ and }(-5,4)$ I do a cheap trick (don't know if that's how you're supposed to do it): I make a function $f : (-1, 2)\rightarrow (-5, 4)$ of the form $f(x)=mx+b$ by \begin{align*} -5 = f(-1) &= m(-1)+b \\ 4 = f(2) &= m(2) + b \end{align*} Solving for $m$ and $b$ I find $m=3\text{ and }b=-2$ so then $f(x)=3x-2.$  Then I show that $f$ is a bijection by showing that it is injective and surjective.


I had a click function which functioned when I had this elements hidden on page load, and then showed them later. Now I am appending those elements on click after the page has loaded, and the function of course doesn't work. I thought I would fixed the problem with load() function but it still doesn't work. This is the html I append on click:  $('#magazine-detail')[0].innerHTML = '

Neste utgivelse

Forrige utgivelse

<button class="button primary expand">Kjøp abonnement - 1 måned gratis</button><button class="button secondary expand">Bla igjennom arkivet</button>

';   There I create #forward and #back elements, for which I have functions on click in my script:  $(document).ready(function () {     var imagesIndex = 0;     nextImage = 0;     loadedImages = new Array();      function preload() {         for (i = 0; i < 2; i++) {             if (nextImage < images.length) {                 var img = new Image();                 img.src = '/imagecache/cover/' + images[nextImage];                 loadedImages[nextImage] = img;                 ++nextImage;             }         }     }      $('#forward').load('click', function() {       imagesIndex++;       preload();        if (imagesIndex > (loadedImages.length - 1)) {           imagesIndex = loadedImages.length - 1;       }        $('#image').attr({"src" : loadedImages[imagesIndex].src, "alt" : name});     });      $('#back').load('click', function() {         imagesIndex--;          if (imagesIndex < 0) {             imagesIndex = 0;         }          $('#image').attr({"src" : loadedImages[imagesIndex].src, "alt" : name});     }); });   I have tried with:  $(document).on('click','#forward', function() {       console.log('entered');       imagesIndex++;       preload();        if (imagesIndex > (loadedImages.length - 1)) {           imagesIndex = loadedImages.length - 1;       }        $('#image').attr({"src" : loadedImages[imagesIndex].src, "alt" : name});     });      $(document).on('click','#forward', function() {         imagesIndex--;          if (imagesIndex < 0) {             imagesIndex = 0;         }          $('#image').attr({"src" : loadedImages[imagesIndex].src, "alt" : name});     });   But nothing gets logged when I click on the element.

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.


In the code given below, if I compile using WinEdt and XeLaTeX, my equation comes out like:    However, when I use PFDLaTeX to compile, the equation comes out correctly:    How to get the equation to show up correctly using XeLaTeX?  Here is the code:  \documentclass{book}  \usepackage{amsmath,amsfonts,amssymb,amsthm, bm} \usepackage{tikz}  \usetikzlibrary{tikzmark,calc,arrows,shapes,fit,decorations.pathreplacing,pgfplots.groupplots, matrix} \tikzset{every picture/.style={remember picture}}  \begin{document}  \begin{equation} \tikz{\node{\subnode{d4}{$\hat{{\theta}}_{BLU}(k+1)$} = \subnode{d5}{$\hat{{\theta}}_{BLU}(k)$} + \subnode{d6} {$\mathbf{K_{B}}(k+1)$}\subnode{d7}{$\big(\underbrace{z(k+1)-\mathbf{h}'(k+1)\hat{{\theta}}_{BLU}(k)}\big)$}};} \end{equation}  \begin{tikzpicture}[remember picture,overlay] \draw[blue,thick,->] (d4) to [in=90,out=245] + (245:2.2cm) node[anchor=north,text = black] {current estimate}; \draw[blue,thick,->] (d5) to [in=90,out=265] +(255:1.1cm) node[anchor=north,text = black] {previous estimate}; \draw[blue,thick,->] (d6) to [in=90,out=265] +(279:2.0cm) node[anchor=north,text = black,text width=3cm,align=center]  {(gain)\\ The weight\\ of the adjustment}; \draw[blue,thick,->] (d7) to [in=90,out=265] +(335:1.6cm) node[anchor=north,text = black,text width=4cm,align=center]  {residual prediction\\ how far the previous\\ estimation from the \\ current measurement}; \end{tikzpicture}  \end{document}

I just read a book "Linear Algebra and Its Applications 4E" by David C. Lay. The book is (should be) LaTeX typeset. The matrix and equations are so nice, please see the following 3 examples:        It's so beautiful, so I want get the same effect inside my paper. Here is my code:   \usepackage{amsmath} \usepackage{colortbl} \newcommand\y{\cellcolor{clight2}} \definecolor{clight2}{RGB}{212, 237, 244}%  %%% \[A=\left[ \begin{array}{ccccc} \y 0 & -3 & -6 & 4 & 9 \\    -1 & \y -2 & -1 & 3 & 1 \\ -2 & -3 & 0 & \y 3 & -1 \\ 1 & 4 & 5 & -9 & -7      \end{array} \right]\]  \[A=\left[\begin{array}{cccccc} \rowcolor{clight2} 3 & -9 & 12 & -9 & 6 & 15\\ 0 & 2 & -4 & 4 & 2 & -6 \\ 0 & 3 & -6 & 6 & 4 & -5 \end{array} \right]\]   And the result:     But how to add these arrows??


Why when I use multiplication  float a= 1.0500000f; float b= a*100.0f;   why b is 104.99999 but not 105.0 ?   and when I   int f= (int)b;   f is 104

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


Given that  $E=\{(x,y) \in \mathbb{R^2}:|x| \leq1,|y|\leq1\}.$ function $f(x,y)=\displaystyle \frac{x+y}{1+x^2+y^2}$  where $f:E\to \mathbb{R}$ Then the range of $f$ is  $1)$ connected open set $2)$ connected closed set $3)$bounded and open set $4)$closed and unbounded set  Solution i tried- The given function is continous ,so a continous function maps a connected set to connected set and also $E$ is a compact set so its image under the continous function will be compact ,from all this option $2$ will be true ,but my answer is wrong , Please help

I am stuck with the following problem:  Let $\,E=\{(x,y) \in \Bbb R^2: |x| \le 1,|y|\le 1\}.$ Define $f \colon E \to \Bbb R$ by $f(x,y)=\frac {x+y}{1+x^2+y^2}$ .Then the range of $f$ is :  connected open set  connected closed set  bounded open set  closed and unbounded set.    In case of option 4, it is not unbounded as $|x| \le 1,|y|\le 1$ and hence $1+x^2+y^2 \le 3$ and also WLOG by taking $ 0 \le x,y \le 1$, we get $x+y \le 2$ and hence $f(x,y)$ must be bounded set. So, option 4 can not be true. But I am not sure about the other options. Can someone explain? Thanks and regards to all.


I flagged this one as "not an answer":      My flag got declined:     declined - flags should not be used to indicate technical inaccuracies, or an altogether wrong answer   Can anyone explain why (for this particular case)?  It is clearly a link-only answer, and the answerer did not provide any information to why this would be useful to the OP. I would understand if they said at least something, that makes it relevant to the question. Then it would be arguable.  Is it just a moderator's error? I am pretty sure to have voted the same way in >100 of other different cases, and they were all accepted.

Related:  (not a dupe, that's a feature request and was closed as a dupe of another one)        (old) post does indeed say that Link-only answers can be flagged as NAA, but there are a lot of posts like  which define Not An Answer is a way that it doesn't apply to link-only answers.  Can we get some up-to-date consensus on this? That link only answers are not allowed is .


$\lim_{n\to \infty} (1 +\frac{1}{n}\tag{displayed})^{n^2} = \infty$  I don't know how to tackle this one. Knowing that it diverges to infinity and thus does not have an upper bound, should I try to prove that it's an unbounded subsequence, if so how? Is that sufficient to show that $\infty$ is the limit?  Any help would be appreciated.

How can I compute the limit $\lim_{n\rightarrow\infty}\left(1+\frac{1}{n}\right)^{n^2}$? Of course $\lim_{n\rightarrow\infty}\left(1+\frac{1}{n}\right)^{n} = e$, and then $\left(1+\frac{1}{n}\right)^{n^2} = \left(\left(1+\frac{1}{n}\right)^n\right)^n$. Since the term inside converges to $e$, the whole thing is $e^n$, and can I conclude that the limit is infinity as $n\rightarrow\infty$?


Here's a problem that has had me scratching my head for a long time:  Imagine you're in a game show, and are presented with 2 boxes.  You are told that both boxes contain a sum of cash, but one of the boxes contains twice as much as the other.  You do not know which box has the double prize.  The game works in 2 phases:   Choose any of the boxes you want. Look inside the box.  At this point you can decide to keep the contents, or switch to the other box.   So imagine that you've chosen a box, and it contains \$100.  From here, you can calculate the "expected value" of the other box to be $0.5 \times \$50 + 0.5 \times \$200 = \$125$ and therefore decide to switch.  But then it follows that you would have made the same decision for any value $x$ that you would have found in the first box!  So then why not just pick the other box in the first place?  In other words, the strategy of "pick a box at random, and then switch, no matter what" is equivalent to "pick a candidate box at random, and then pick the other box, and keep it", which is also equivalent to "pick a box at random, and keep it".  Which means that switching is the same as not switching.  But this seems like a paradox, because we just calculated that switching the box after your initial choice increases your expected winnings by a factor of 1.25!

I have been trying to solve , but in vain. Please help.     You are given two boxes with a number inside each box. The two numbers   are different but you have no idea what they are. You pick one box to   open; read the number inside; and then guess if the number in the   other box is larger or smaller. You win if you guess correctly, and   lose otherwise. Is there anyway that you can win the game with more   than 50% chances no matter what the two numbers are?


It took like forever to figure out where I can find the minimap in MK8, and now that I found it it's still really annoying always having to look down when I want to know where the other characters are.  Is there a way to Move the Minimap from the gamepad to the Main screen? And if yes: How can I achieve this?

In Mario Kart 8 the Wii U gamepad can display a map that will show a general overview of the current course, as well as your current position, and those of your opponents on the map. It will also list all players and give some information about them.  However, I don't use the gamepad to play, and I thus I can't see any kind of map. I personally always like to have a general idea of where I am to measure how far ahead or behind I am, and without the gamepad it seems I can't.   Is there any way at all to get a map to display on the TV, so I'm not tied down the the Wii U gamepad?  NOTE: I'm not particularly looking to have the player list onscreen, but if that is also possible, it's worth mentioning.


When I enter my value for the String 'decision' as 'Yes' the if statement then acts as if the value of decision is anything but 'Yes' by executing the line System.out.println("Please continue shopping");  What can I do to fix this? Here is the class the problem is in:    //paying for this instance of a basket public void payBasket(double cash){     String decision;     double balance;     System.out.println("You have £" +cash);     decision = null;     if(cash > endTotal)     {System.out.println("You have enough money to pay for this basket");     }     else      {System.out.println("You need more money before you can pay for these items");};     BufferedReader reader;     reader = new BufferedReader(new InputStreamReader(System.in));     System.out.println("Would you like to pay for this basket?");     try{      decision = reader.readLine();     }     catch (IOException ioe){         System.out.println("an unecpected error");     }      if(decision == "Yes"){balance = endTotal - cash;         System.out.println("Your current balance is " + balance);}         else {System.out.println("Please continue shopping");         } }

I've been using the == operator in my program to compare all my strings so far. However, I ran into a bug, changed one of them into .equals() instead, and it fixed the bug.  Is == bad? When should it and should it not be used? What's the difference?


I want my script to cut geometry faces with knife tool. I read about bpy.ops.mesh.knife_tool() but there's no parameter for specifying the cut path. Is there an example or reference on how to use knife tool through python script?

Hello I'm quite new in this api. I want to use knife_tool from bpy.ops.mesh on the selected face. When I just call (like in tooltip):  bpy.ops.mesh.knife_tool()   I get error:  Traceback (most recent call last):   File "<blender_console>", line 1, in <module>   File "/home/t/blender-2.71-linux-glibc211-x86_64/2.71/scripts/modules/bpy/ops.py", line 188, in __call__     ret = op_call(self.idname_py(), None, kw) RuntimeError: Operator bpy.ops.mesh.knife_tool.poll() failed, context is incorrect   I tried in edit and object mode. Maybe is any other way to cut face in my own points from console?


I''ve downloaded tar file from oracle server but I don't know how to install it on my ubuntu linux system. Could you please provide step by step details on how to install it? Thanks

I want to install Oracle's JRE and to update to the latest version with the Software Updater when they released. Is there a Ubuntu package that is provided by Canonical or Oracle?  Before release Java 7, I followed  to install Java 6.  But it doesn't work for Java 7. There is no package sun-java7-xxx. How can you install Java 7?


I'd like to ask question to get recommendations regarding some framework/technology choices. When I typed question in StackOverflow I got warning that question is subjective and is likely to be closed. Should I try programmers@stackexchange instead?  Here is the question I wish to ask to fellow programmer around the world:     Which Java web framework do you recommend for intranet webapp (not content website)?

There is . Is the site appropriate for stuff related to requesting frameworks and libraries? Or should we have another site for that (e.g. name it Frameworks Recommendations or stuff alike)?  I can ask stuff there like: I need a software satisfying W, X, Y, and Z, but I'd like -some day- ask like: I need a Python library satisfying W, X, Y, and Z. The audience may be (and perhaps will be) different.    Is that website on-topic for stuff like that? Or should we open another proposal for that?  No: It's not about asking for a giga-dump for subjectivish questions. The linked-to-dupe question was written and answered with an old mindset and without Software Recommendations in mind. Also it does not consider this specific kind of questions but all the crap in one place. So, no,  is not an appropriate dupe mark for this question.


I understand that $\vec{D}=\varepsilon_0 \vec{E} + \vec{P}$, but, physically, what is the difference between these two vector quantities? What is their physical meaning?

$$\mathbf D = \varepsilon \mathbf E$$ I don't understand the difference between $\mathbf D$ and $\mathbf E$.  When I have a plate capacitor, a different medium inside will change $\mathbf D$, right? $\mathbf E$ is only dependent from the charges right?


Are any of the following correct?     It's all too-easy   It's all-too-easy   It's all too easy   Explanation/citations would be greatly appreciated

Some compound words are written without hyphens (nonaggression, nonbeliever), some with hyphens (well-intentioned), and others with spaces (post office).  Is there a rule or good guide as to which option should be used?


I read this sentence: "They all helped load up the car." I cannot understand why "to" is missing here. As "They all helped to load up the car." I can be wrong but "to" makes more sense to me. But there must be some point behind omitting "to" that I cannot understand and need help with.

I wrote:      I will help you to acquire Russian.    A native English speaker corrected me saying that 'to' is unnecessary here. Is it correct to say      "I will help you acquire Russian"


It's she who had to leave her family. It's hers who had to leave her family.   What's difference in between? Are they grammatically correct? I'm not sure about the use possesive pronouns in the second sentence.

It is me who am to blame.    It is I who am to blame.      Which one is correct here? I am bewildered about these two sentences.


I tryed to install Skype and then this  Website works fine,I rebooted but it still does not work I also imported their certificate.Is there anything I can do?  Here's the poignant part of the error:  Err https://download.01.org/gfx/ubuntu/14.04/main/ trusty/main libdrm2 i386 2.4.56-1   Failed to connect to download.01.org port 443: Mreža je izvan dosega Err https://download.01.org/gfx/ubuntu/14.04/main/ trusty/main libdrm-intel1 i386 2.4.56-1   Failed to connect to download.01.org port 443: Mreža je izvan dosega E: Failed to fetch https://download.01.org/gfx/ubuntu/14.04/main/pool/main/libd/libdrm/libdrm2_2.4.56-1_i386.deb  Failed to connect to download.01.org port 443: Mreža je izvan dosega

I should begin by mentioning that I am very new to Ubuntu and I am in the process of getting used to it.  Every time I try to update it gives me back an error. I have put it here in my question. Please tell me what to do.   Ign http://archive.ubuntu.com trusty/main Translation-en_IE                     Ign http://archive.ubuntu.com trusty/multiverse Translation-en_IE               Ign http://archive.ubuntu.com trusty/restricted Translation-en_IE               Ign http://archive.ubuntu.com trusty/universe Translation-en_IE                 Err https://download.01.org trusty/main amd64 Packages                            server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none Err https://download.01.org trusty/main i386 Packages   server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none Ign https://download.01.org trusty/main Translation-en_IE Ign https://download.01.org trusty/main Translation-en W: Failed to fetch https://download.01.org/gfx/ubuntu/14.04/main/dists/trusty/main/binary-amd64/Packages  server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none  W: Failed to fetch https://download.01.org/gfx/ubuntu/14.04/main/dists/trusty/main/binary-i386/Packages  server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none  E: Some index files failed to download. They have been ignored, or old ones used instead.


Recent Places is a great feature in Windows 7 and up, but it's frustrating to me that it's always sorted in alphabetical order on the folder name. The result is that the most recent place isn't at the top. When I access Recent Places in an application such as Word, I have to click the date column (every time) to make it re-sort the list of folders.  How can I set it so that the contents of Recent Places is always sorted by order of most recent folder first?

I used to always have the Recent Places shortcut folder sorted by date modified (which is the only reasonable way to sort it). But some time ago it started sorting it by name automatically. No matter what I try it seems that I can never get it to remember to sort by date. Even if I click the Date Modified column header, then navigate to another folder and then come back it is sorted by name again! No other folder behaves like this. Do other people have this problem? Any way to fix it?


When I make any data transfer process (from computer to usb), after a couple of seconds file transfer process freezes. It be normal after a few minutes later but again freezes. If there would no problem, copy process will be fast. Unlikely my hard-disk works without any problem. Also Flash-disk hasn't got any problem. -I disgust to say that- USB works fine in other OSes.  Note: I am using 3.0 port and 3.0 USB-Driver. I have no 2.0 port on my laptop.

Yesterday I was copying a single, 8 GB file to a USB with a slow, 7 MB/s write speed, while my RAM is 3 GB. While copying the system froze, to the point where I couldn't even move the cursor.  I managed to log into the text console, and ran iotop, it showed that a process named kswapd0 was taking 99.99% of IO.  Are there workarounds so copying a large file doesn't make my system unusable?


The crow doesn't get an electric shock while sitting on only one electric line because it has the same potential as that of the line. Since there is no potential difference the charge does not flow through the crow's body unless the crow touches the neutral line and creates a potential difference between one end of its body to the other. How could the crow attain this much electrical potential? The crow was at a zero potential when it came and sat on the line. Was there any charge flow to the crow's body from the line? If there was, how could the crow survive such a potential hike?

When we touch electric wires, we get shocked. Why don't birds sitting on electric wires not get shocked?


I have a homework in real analysis and I'm very confused about it. I would be very thankful, if you could give me any ideas or solutions how to get this task done. The task is as follows:     Find the limit:   $$\lim_{x\to 0} \frac{1}{x} \int_{0}^{x} (1+ \sin(t))^{1/t} dt.$$   A hint that has been given is to use L'Hospital's Rule. Moreover, it must be substantiated why we can use L'Hospital' Rule in this situation. It is also important to mention that $(1 + \sin(t))$ has a removable point of discontinuity at $0$ and therefore the integral can be interpreted as a Riemann integral.


I'm trying to flatten and deep copy of an object.   Here's an example of how I try to do:    const data = {   firstObj: {     data: 'Hi!',     nestedArrayOfObject: [{       name: 'hey',       property: 'object'     }],   },   secondObj: {     name: 'second',     nestedArray: []   }, }  const object = {} const keys = Object.keys(data)  for (let i = 0; i < keys.length; i += 1) {   const items = Object.keys(data[keys[i]])    for (let j = 0; j < items.length; j += 1) {     object[items[j]] = data[keys[i]][items[j]]   } }  console.log(object)     As I understand, nested objects are being only linked to the new object, but not cloned.   How to do it correctly without additional libraries?

What is the most efficient way to clone a JavaScript object? I've seen obj = eval(uneval(o)); being used, but . I've done things like obj = JSON.parse(JSON.stringify(o)); but question the efficiency.  I've also seen recursive copying functions with various flaws.  I'm surprised no canonical solution exists.


What is the value of $f(x) = x \ln (x)$ at $x= 0$?   Is it $0$ or indeterminate?

Why is the limit of $x \log x$ as $x$ tends to $0^+$, $0$?   The limit of $x$ as $x$ tends to $0$ is $0$. The limit of $\log x$ as $x$ tends to $0^+$ is $-\infty$. The limit of products is the product of each limit, provided each limit exists. Therefore, the limit of $x \log x$ as $x$ tends to $0^+$ should be $0 \times (-\infty)$, which is undefined and not $0$.


I just moved all of them into Sun/Moon but the game doesn't seem to notice, even if I move a Pokemon I got from another game into the party.   How do I get the National Dex?

I'm at roughly 67% completion of the Alola Dex, with ~200 caught, ~290 seen. After scanning QR codes, I've caught a Swinub and Cyndaquil. However, neither were registered in the Pokédex, since neither are Pokémon in the Alola Dex. This brought up the following question:  When will I unlock the National Dex?   Do I need to have seen all the Pokémon in the Alola Dex? Do I need to complete some specific quest, like catching/defeating the Ultra Beasts?


I had a problem with libre office (overlapping text with images) as mentioned in my previous  . So I copied Fonts from windows and placed it in /usr/share/fonts . Some fonts from windows are of .fon and some are of .TTF type .  I found a similar question  but I am not aware of using  project.I am expecting a detailed answer.

I like the ProggyClean fonts a lot and would like to see them in my terminal. The "True Type Font" versions aren't great, but the bitmap (raster, *.fon) fonts are excellent. This should be a virtue since the Linux fonts are all raster as a matter of course.  I think the Linux font format is PSF2 (among others?) and is detailed here: .


The story begins with the narrator waking up on an airplane due to a "bump," which she assumes to be from turbulence. Everything seems normal at first, and her thoughts drift. I think most of the text is her own internal monologue and reminisces, but she keeps noticing minor details that strike her as strange. She slowly comes to suspect that the plane was destroyed (by a bomb?) and everyone aboard is being taken into the Egyptian afterlife.  The flight may have been on its way to Cairo or may have just been flying over the area, but I don't recall any particular reason why it should have been the Egyptian afterlife other than that. She may have spotted some pyramids through the window and been thinking about the funeral preparations for the afterlife journey of the ancient Egyptian kings somewhere early in the story.  Towards the end, she looks out the window and spots crocodile-like monsters in the river (the Nile) below. It ends on a note of continuing ever onward into the unknown as things slowly become stranger. I was pretty sure that this was a Dan Simmons story, but I don't see any promising short fiction titles in his bibliography.  I was reminded of this story by , but this is apparently not the same one. The story about which I'm thinking definitely begins with the narrator waking up on the plane, and the plane's cabin (plus what can be seen out its windows) is the setting for the entire story.

This short story is set in one of one the pyramids of Egypt, I think. It may not seem like sci-fi, but I’m pretty sure I read it in a science fiction anthology.  The narrator is part of a tour group off to tour a pyramid. As the group makes its way to the site, the narrator begins to notice fleeting images of strange creatures near the group. For example, he glimpses a baboon-like animal darting about on the face of the pyramid.  Once inside the pyramid, the group goes deeper and deeper into the structure. Slowly it dawns on the narrator that perhaps they are all dead and they are descending into the underworld. He is the only one cognizant of this possibility it seems. Everyone else seems oblivious as they listen to one member of the group read text from a guide book. I think the last line of the story is something to this effect:     We continue to descend.


Let p be an odd prime, where a,b are integers such that $p\nmid a$ and $p\nmid b$. Show that the congruence $(x^2-a)(x^2-b)(x^2-ab) \equiv 0\bmod p$ is always solvable.    I know that (a/p) and (b/p) is equivalent to $(-1)^{(p^2-1)/8}$

Let p be an odd prime and let a,b ∈ Z such that p ∤ a. Prove that the congruence $(x^2-a)(x^2-b)(x^2-ab)$ ≡ 0 (mod p) is always solvable.   Not sure where to begin here.


Are they spinning around the nucleus? If so what makes them move? I just do not understand how they move or if they are "attracted" to something is it another particle that makes it move.

I need to get a nice picture about how electron moves around nucleus? I find concept of probability and orbitals quite difficult to understand?


When writing code in C, I often include const in function parameter declarations in the function's definition, but not its declaration:  int func(int arg);  ...  int func(int const arg) {     return arg + 1; }   This has always compiled for me without issue using GCC and Clang, but Microchip's C18 compiler is claiming a type mismatch.  What does the standard have to say about this? Have I been relying on a non-standard extension?  Edit: I am not asking about the benefits of this and I am not asking about C++ as in the supposed duplicate question (). I am asking about the C standard: Is this legal ANSI C, C99, or C11?

How far do you go with const?  Do you just make functions const when necessary or do you go the whole hog and use it everywhere?  For example, imagine a simple mutator that takes a single boolean parameter:  void SetValue(const bool b) { my_val_ = b; }   Is that const actually useful?  Personally I opt to use it extensively, including parameters, but in this case I wonder if it's worthwhile?  I was also surprised to learn that you can omit const from parameters in a function declaration but can include it in the function definition, e.g.:  .h file  void func(int n, long l);   .cpp file  void func(const int n, const long l)   Is there a reason for this? It seems a little unusual to me.


I took some photos of the moon last night.  I wanted good color without a lot of noise, so used ISO 100 and a long exposure (10 seconds with a 400mm lens).  I have a good tripod and head and used a 2 second shutter delay so that I wasn't touching the camera.  This has worked great for me for terrestrial shots in the past, but the earth turns enough in 10 seconds to give the shot a very directional blur.  Oops!  I'm familiar with Sharpen, Unsharp Mask, and similar filters.  I'm specifically wondering how to sharpen only in one direction.  Like a sharpen filter where I specify an angle and a length.  I know the earth makes an arc, not a line, but a line would be close enough to fix this.  Also, I run Ubuntu 18.04 Linux.  I normally use Darktable and Gimp, but can try other things or an online service.  It does not have to be free.  I just can't use Windows-only or Mac-only software.

I have heard quotes which say "If its not good, delete it."  I go by that advice, but sometimes you capture some precious moment but you see that photo is slightly blurred because of camera shake. I don't have an IS lens, and it's too late to somehow do it over.  What best one can do in post processing to improve the quality of the picture?  Ideally, I'd like to use Gimp or Picassa for this.  Edit: I came across a video regarding this -


Tell me how to get another password don’t recall what I used. Thanks

I changed my passcoad and I choosed off passcoad and then close my iph.