I accidentally removed my /etc/apt/sources.list file. Is it hosted by Canonical somewhere so I can re-add it to the system? It's a bit of an emergency, so I hope someone can provide a quick answer.

I am looking for the best method to restore /etc/apt/sources.list to default from the command line.  Is there no way to reference the source code of the package which generates this file or something like that? I want a trusted and version-independent way of restoring this file.  Solutions Ruled Out  Before you mark this as a duplicate, note that I have reviewed  already. It is only applicable if you have the Ubuntu GUI available. This question is specific to the command line.  I have also reviewed  where the accepted solution is someone pasted the contents of their sources.list file. This is not an appropriate way to restore the file as the intentions of the person providing the file contents cannot be verified and the file is subject to change with new releases.  I checked out the , but this is also not from Ubuntu so I do not plan to use it.


Recently I have been randomly downvoted and I suspect it is the same user. The user doesn't stop at downvotes. He/She ensures that he/she upvotes the other answer where I have replied no matter how good my answer is. Fair enough, I don't loose my sleep over it but how do you deal with such users? So I thought of searching meta and I came across  question where a mod did specify that      If you suspect you've been downvoted by a particular user, flag the thing that makes you suspicious of that user (a comment they made to that effect for example).   There was another thread which I am still searching but unable to find where a mod had said the same thing... "To Flag It"  On three occasions, I did that. On two occasions, It was marked as helpful but on the 3rd, I was confused with the Mod comments.    My Question  Can any mod share some light on it? When can or can't a mod help with downvotes?  I am not worried about reversals. I want to understand the process and hence my question above. If you see  link, the last line says that      If you find you are the victim of serial voting multiple times within a short time span, feel free to flag one of your posts for moderator attention and explain the situation so they can investigate further.   If the mods seriously can't do anything about it then I will stop flagging. Let those users downvote/upvote and be happy for all that I care :)  I am ready to accept an answer by a mod which can be as simple as "Sorry, We can't do anything"

I don't know if I'm being paranoid - but earlier I made a comment on a question that showed no research effort:  . I got a rather snarky reply, and a couple of minutes later I noticed that two of my top questions (which are otherwise on completely different topics) received downvotes within a minute of each other.        It is hard not to suspect a connection between these events, especially in light of the tone of follow-up comments made by the OP (who might not have noticed that I helped improve the answer that was ultimately accepted in the mean time).  Not sure if I am being over sensitive or paranoid; should I just move along? "Spiteful downvote" gets quite a few hits on this site, and maybe I am just too new to be immune to it.  My question(s): "Is there a process to reverse such behavior? Do the comments in the above question merit a flag? Should I shrug an move on?" Any words of advice or encouragement appreciated. Sorry if I sound whiny.  update - the question linked above has been removed "for reasons of moderation". Probably a good outcome. I appreciate all the helpful inputs this generated!  edit This is quite different than the question cited as the duplicate: in that one, a person lost reputation because a user was removed; in this case I suspect an individual user down voted two of my top questions in quick succession "out of spite". The message (shown above) in the rep dashboard was quite different... I request this question be re-opened.


In all of the bathrooms, there is a recessed light/exhaust fan combo installed. I assume, due to the combo feature, is the reason there is no cover over the light fixture.  However, the same light/exhaust is also located inside the master shower - not in the damp area but, the actual wet area.  Visualize yourself taking a shower and looking directly above you as your washing your hair, with water spraying and splashing everywhere, you look right up into the can of the light!  So, out of precaution, we keep the switch off -ALL THE TIME! Is this safe and to code?

I am in Montgomery County, Maryland and I had a contractor tell me it's against code to put a recessed light in my shower. The shower is 3' X 3' X 7'1" (3 foot by 3 foot and the height is 7 feet 1 inch).   Here are my questions:   Can I put a recessed light with shower trim in that shower? (Everything I see says I can) Do I need a special high pressure light as it's under 8 feet tall? (And If so, what do I buy?) Any other code related questions that I should be aware of?   I researched it and put the light in and this contractor (who does this for a living) tells me an inspector would reject it, which I don't believe as recessed lights in showers are everywhere these days.


I wonder how can calculators or Wolfram evaluate such expressions as $2^{1.35}$ or $3^\pi$.   Do they use Taylor series for $2^x$ and $3^x$ or do they employ other means?

I just wanted to directly calculate the value of the number $2^{3.1}$ as I was wondering how a computer would do it. I've done some higher mathematics, but I'm very unsure of what I would do to solve this algorithmically, without a simple trial and error.  I noted that   $$ 2^{3.1} = 2^{3} \times 2^{0.1} $$  So I've simplified the problem to an "integer part" (which is easy enough) :  $2^3 = 2\times 2\times 2$, but I'm still very confused about the "decimal part". I also know that :  $$ 2^{0.1} = e^{0.1\log{2}} $$  But that still presents a similar problem, because you'd need to calculate another non-integer exponent for the natural exponential. As far as I can see, the only way to do this is to let:  $$2^{0.1}=a $$   And then trial and error with some brute force approach (adjusting my guess for a as I go). Even Newton's method didn't seem to give me anything meaningful. Does anybody have any idea how we could calculate this with some working algorithm?


I don't know about the Sylow Theorems.  But I have been wondering about a proof of the fact that a group or order $pq$ where $p$ and $q$ are distinct primes must be cyclic. I can't quite work out the details, but here is the general idea. I would like help with filling in details. I assume that it is already known that $G$ has subgroup(s) of order $p$ and subgroup(s) of order $q$.  If $G$ is a group of order $pq$ ($p\neq q$), then I know that $G$ has a subgroup $H$ of order $p$ and a subgroup $K$ of order $q$. Then $H\simeq \mathbb{Z}_p$ and $K\simeq \mathbb{Z}_q$.   But then $H\oplus K \simeq \mathbb{Z}_{pq}$, so I would think that $H\oplus K \simeq G$. I guess one could do an internal direct product instead of an external direct product, but I don't know that $H$ and $K$ are normal subgroups.  I am asking for help completing this argument.  Edit: I see from the comments below that I might need to assume that the smaller prime does not divide the larger prime minus $1$. Or maybe it is enough to assume that the primes are greater than or equal to $3$ (Still distinct).

There is a proposition in Beachy and Blair's Abstract Algebra that I don't entirely follow. The proposition is the following:   Let $G$ be a group of order $pq$, where $p > q$ are primes.  a) If $q$ is not a divisor of $p-1$, the $G$ is cyclic.  b) If $q$ is a divisor of $p-1$, then either $G$ is cyclic or else $G$ is generated by two elements $a$ and $b$ satisfying the following equations: $$a^p = e, \\ b^q = e,\\ ba = a^nb $$ where $n \not \equiv 1  \ (mod \ p)$ but $n^q \equiv 1 \ (mod \ p)$.  Can one of you prove how this is true? I understand a similar proof for when $q=2$, but this one is more complicated.


I see that there are 2 people in my school connected to my iTunes library. how would i go about finding out who it is, other than just the ip. Maybe try to figure out like their computer name or something like PersonA's macbook.  I'm also new to apple and all these commands. A walk through would be helpful thank you.  -s

Is it possible to see who is currently connected and listening to a shared iTunes library? Is it possible to see which songs they listen to and how many/often?  It's not really important; I'm just curious about it. Would be nice to know which colleagues love my music…


How do i show that the curve $y=\frac a{x^2}$ is a horizontal stretch of the curve $y=\frac 1{x^2}$ and how do i find the stretch factor? i have tried and added k constant in front of $x^2$, so $y=\frac a{kx^2}$ but not sure where to go from there.

I know $y=2f(x)$ doubles the $y$ value in vertical shifting, and I know that $y=(1/2)f(x)$ halves the $y$ value. But, why does $y=f(2x)$ halve the $x$ value, and why does $y=f((1/2)x)$ double the $x$ value in horizontal shifting? I looked at the graphs, and I see the difference, but I want to know the math behind why it halves instead of doubling the $x$ value for $y=f(2x)$. Maybe this is a stupid question, but could someone help me out?  Thank you.


I'm fairly new to data analysis. I'm working with a dataset of around 40k observations and looking at the correlation between those variables and my target variable. I'm trying to understand more about correlation coefficient (calculated using Pearson's R) and linear regression. Assuming my dependent variable and an independent variable has a correlation coefficient of -0.16 which is by all accounts a weak correlation, if I plot these two variables using a scatter plot with a regression line I can see a downward trend. However another of my variables might share a lower correlation coefficient with my target variable but show a steeper regression line. Does this not mean that the correlation coefficient should be higher? Thanks in advance

I would have expected the correlation coefficient to be the same as a regression slope (beta), however having just compared the two, they are different. How do they differ - what different information do they give?


Studying asymptotics, I bumped into the concept of Observed Fisher Information, as a way to compute Fisher Information when the parameter $\theta$ is unknown. I am also aware that it is related in some ways to Maximum Likelihood Estimators but I am a bit confused.   Thus my questions are: Which is the difference between Expected and Observed Fisher Information? How the observed Fisher information is computed? And how it is used?  EDIT: From the linked pages, I have understood how the Observed Fisher Information is computed and how it may be better than the Expected one in cases of finite samples.  But I have some doubts yet: is the only difference between Observed and Expected Information the presence of an estimate (possibly the MLE of $\theta$) or a  known $\theta$ ? Thus, should it be used, for example, in the case of asymptotic estimations?

In the standard maximum likelihood setting (iid sample $Y_{1}, \ldots, Y_{n}$ from some distribution with density $f_{y}(y|\theta_{0}$)) and in case of a correctly specified model the Fisher information is given by  $$I(\theta) = -\mathbb{E}_{\theta_{0}}\left[\frac{\partial^{2}}{\theta^{2}}\ln f_{y}(\theta) \right]$$  where the expectation is taken with respect to the true density that generated the data. I have read that the observed Fisher information   $$\hat{J}(\theta) = -\frac{\partial^{2}}{\theta^{2}}\ln f_{y}(\theta)$$  is used primary because the integral involved in calculating the (expected) Fisher Information might not be feasible in some cases. What confuses me is that even if the integral is doable, expectation has to be taken with respect to the true model, that is involving the unknown parameter value $\theta_{0}$. If that is the case it appears that without knowing $\theta_{0}$ it is impossible to compute $I$. Is this true?


If the electrical signals from all the various organs throughout the body eventually connect to the nerves in the spinal column traveling up to the brain, how does the brain differentiate the different signals.  Is the nerve in the spinal column like an electrical conduit with many wires inside?

I am an electronic engineer so I am thinking about this from an electronics outlook.  How does the addressing system work, As I see it, the nervous system is small parallel branches attached to larger "serial" lines (spinal cord).  The serial line is then attached to the brain, but how does it then figure out where the message came from and then get the message back to the place it came from.  If I were to build a robot I would have an addressing system with each message and maybe some kind of error checking to make sure the messages don't become corrupted, but as it's not an electronic system I don't see how the brain could possibly do this. unless it is a fully parallel system and there is a single wire going from every sensor back to the CPU..


I want to add my institution logos to my CV but unfortunately they don't appear the shape of picture that I want. How should I edit the code to make the picture circle?

\documentclass[demo]{article} \usepackage{graphicx} \usepackage{tikz} \begin{document} \begin{tikzpicture} \node[circle,draw,inner sep=2cm]{\includegraphics{myimage.jpg}}; \end{tikzpicture} \end{document}   How do I modify the above code so that the included image is adapted to the circle shape and cropped of the exceeding parts?  I want to specify a shape (a circle) and then include an image respecting the given dimension and cropped.


Find $x$ and $y$ such that   $$ \binom{100}{0}+2\binom{100}{1}+4\binom{100}{2}+\cdots+2^{100}\binom{100}{100}=x^{y} $$   I started out by letting $n$ be a small number.  Let $n=3$: $$ 2^{0}\binom{3}{0}+2^{1}\binom{3}{1}+2^{2}\binom{3}{2}+2^{3}\binom{3}{3}=1(1)+2(3)+4(3)+8(1)=27=3^{3} $$  Let $n=4$: $$ 2^{0}\binom{4}{0}+2^{1}\binom{4}{1}+2^{2}\binom{4}{2}+2^{3}\binom{4}{3}+2^{4}\binom{4}{4}=1(1)+2(4)+4(6)+8(4)+16(1)=81=3^{4} $$  However, I cannot for the life of me figure out how to use this and solve the original question. More specifically, I know the answer is $3^{n}$, but I don't know how to do a combinatorial proof.

Let $n$ be a nonnegative integer. Prove that   \begin{align} 3^n = \sum_{k=0}^n \dbinom{n}{k} 2^k . \end{align}   I know that $2^n = \sum\limits_{k=0}^n \dbinom{n}{k}$, but how to integrate the $2^k$ into this sum?


I find several questions like mentioned here:  The question OP is not clickable (and often has a name like user123456) and is probably not existing anymore. These questions become orphans with respect to control over the accepted answer when the OP is gone. Often the orphans are ok, since the 'accepted answer' is (I believe) considered from the viewpoint of the person that asked the questions. So when that person is gone then we might say we do not care about the accepted answer. (A bit of track: from my viewpoint the 'accepted answer' is not only about the benefit to the OP and it serves a wider purpose. Because of that it should in my opinion should be controlled by the community and not just a single person. This is especially the case when the OP that asked the question, is possibly having a knowledge gap, and may not always know what a good answer entails, especially what makes an answer a 'correct' answer. But that's a different issue) What do we do with the control of these orphan questions, and especially when the accepted answer is false? (but there is no OP anymore to change this) This question can be taken as an example case:  It's 3 years old and has an accepted and upvoted answer, but... does that close the case?

I have often come upon questions where the asker never bothered accepting what is obviously a correct answer. "Obviously" can mean (aside from my own judgment):   The answer is a clear leader in up-votes (again, combined with my judgment that it is a correct one) The answer is the only one (and again appears correct) The answer (or Q) is commented on by OP indicating it helped.   If the user is still active on SO, what helps sometimes is to post a comment on the question mentioning you can/should accept the answer. For my own answers, this technique worked ~30-50% of the time.  However, if the user is a zombie (showed up >1 month ago, asked one or few answers, and was not on the site for >1 month since), this would obviously not work.  To ameliorate this situation, I would propose allowing users whose rep > threshold to "accept" answers from other peoples questions. This would be limited to:   questions from zombie users as defined above (e.g. total active time on site <= 30% of time since last visit, or however you want to define). questions from non-zombie users with very low accept rates (this may require higher threshold).   In either case,   neither the OP nor "guest acceptor" gains 2 points for accepting. the OP should have the right to choose a different accepted answer at any time, and get 2 points rep when that happens. If you accept your own answer, you obviously don't get 15rep for acceptance.   I think if implemented to the above specs, it should provide enough of a barrier to misuse while serving the goal of the site (allow arriving at the best possible answer).  P.S. This was obviously triggered by some of my own answers but once I realized the situation I observed it numerously with questions I was merely browsing.


Is there something up with the review queue today? In the text it mentions first question but it is really an answer.    Or it mentions first answer when it is really a question.

I believe there is a typo in the  review queue. When reviewing a question, the information message asks the user to review the answer. Take a look at the image below.    Similarly, when an answer is posted in the queue, the description box calls it a question instead. Has anyone else noticed this?


Recently I was looking for this manga that I forgot the name of. I remember  that it was a woman who worked for the government and she ends up at her old high school and sees a man about to commit suicide she tries to help him but ends up falling off the roof with him and somehow gets sent back in time she’ll then have to repeat high school but in the process she will  try to save the man from  the life of crime.

The story is about a young woman, working as a police officer or something. She is in love with a fellow colleague. While visiting her old high school she meets a wanted criminal. Said criminal was about to commit suicide by jumping of a building. The main heroin wanted to prevent this, but falls with him.  Instead of dying she somehow travels back in time into her younger self back in high school. There she meets this criminal, who still hasn't committed any crimes. She now wants to "re-educate" him, so that he won't end up the same as his future self. Meanwhile they fall in love with each other.  Her previous crush from the future somehow ended up in the past as well and they collaborate together to save the "criminal".  I remember reading this manga back in 2017. Back then it was still ongoing.


Want to install Linux so that I can boot to my old windows and another Linux.

Before I start, don't lecture me on the fact that FAT32 is old and hasn't been updated for nearly 20 years. Right now I have sorted that. I am trying to install Ubuntu Linux onto a 64GB flash drive and it wants me to format it to one of the EXT file systems.  The problem is if I put the flash drive into a Windows PC, I can't use it. I also can't install the required software onto every Windows PC that I will use. When I tried to install it on FAT32 I got an error and there is no option for NTFS.  Does anyone know how I could do this? Maybe a Windows based tool? Thanks in advance.


I have read so many articles on so many websites about transistors and everywhere it says that when transistor is acting as a closed switch and conducting the voltage across collector-emitter is 0 volts, so how can the current flow if the applied voltage across two points is 0 volts?

Reading  and its answers (as well as ), it seems that in an idealized short-circuit with zero resistance, one concludes the voltage is zero.  This seems completely wrong.  The justification is given by V=IR. Assuming current is finite you would indeed conclude that V=0. But why would you assume finite current?  Yes, real-world currents must be finite, but real-world resistances must be nonzero. This is an idealization; the idealized values don't have to be physically attainable.  And, in a real-world approximation of an ideal short circuit, one sees very large current; nonzero voltage, infinite current, and infinite power seems like a much more accurate idealization than the finite current, zero voltage, zero power idealization.  Thus my question. Is this idealization of finite current and zero voltage really the common one to make? And why?    Edit: to make it explicitly clear, in this idealization, the parameters of the ideal circuit are allowed to attain idealized values — specifically, a priori, a literally infinite for current is allowed (for mathematical precision, I mean the extended real number ∞). With R=0 and I=∞, Ohm's law puts no constraints on the voltage; every extended real number value for V is consistent.


My friend who recently introduced me to LaTeX always pronounced it "Lay-Tek". Is he wrong? assuming he isn't why is LaTeX pronounced this way when it clearly has nothing to with the X at the end?

Is it tex(tech)? Or Is it tex(like touch)?  Lay-TeX? or La-TeX?  Should I use TeX pronunciation in LaTeX?


Let $n\in\mathbb{N}$ with $n\geq2$. Consider the numbers $n!+2,n!+3,...,n!+ n$. Show that none of them is prime. Deduce that for each positive integer $N$ there is a stretch of $N$ consecutive composite numbers.  The only idea I have is to show they are composite numbers you have to find a non-prime factor. Would anyone be kind enough to start me off?  What I don't understand is what happens when n=2 and you work out n! + 3=5 which is prime.

Can anyone tell me what is the maximum number of consecutive composite numbers possible? I mean can I get say 1000 consecutive natural numbers. Is there any general theorem that when I have a n-digit number there will always be p consecutive composite numbers?


I want to show that $$ \sum_{k=0}^n \frac{(-1)^k}{k+1} {n \choose k} = \frac{1}{n+1} $$ I know, that I will have to use that for $ l \geq 1 $ $$ \sum_{i=0}^l (-1)^i {l \choose i} = 0 $$. My idea is that I write: $$ \sum_{k=0}^n \frac{(-1)^k}{k+1} {n \choose k} = \sum_{k=0}^n (-1)^k {n \choose k} \frac{1}{k+1}$$ but in order to continue with my proof I know that I have to pull out a constant from the sum because I'm pretty sure the last step of the proof ought to be using the second "sum-rule" to make it 0 and there will be only $ \frac{1}{n+1}$ left. Summary: my problem is that I don't know how to get to that second line (beginning at "..that for $l\geq1$") because there is a l and i and in my last line there is a n and a k. Furthermore I don't know how to get that "k+1" to become "n+1" and whether I can just pull it out of the sum since it isn't a constant but dependent upon the k, which is running towards n.

Other than the general inductive method,how could we show that $$\sum_{r=0}^n \frac{(-1)^r}{r+1}\binom{n}{r} = \frac1{n+1}$$  Apart from induction, I tried with  to check the validity, but I can't think of an easy (manual) alternative.  Please suggest an intuitive/easy method.


I am trying to achieve the best permalink structure for my site. It will be a multi-author site where users will be posting artciles on a daily basis.  I want the permalink structure to be as follows:  http://sitename.com/username/postname   However, I have seen many sites that put the post date in the permalink like this:  http://sitename.com/username/postdate/postname   What would you advice me to do?  Will I get any advanteges on using the post date in my permalink strcuture regarding SEO?  PS: I already checked out this answer  but I was not happy with it.

I was curious about the date in URL segments, is there any SEO point of benefit? For example the following URLs:  http://techcrunch.com/2013/06/18/netflix-will-launch-in-the-netherlands-later-this-year-as-its-international-expansion-slows/ http://tips-for-new-bloggers.blogspot.in/2007/02/adding-favicon-icon-to-blogger-url.html  https://community.jivesoftware.com/blogs/jivespace/2013/05/15/eol-of-the-html5-ipad-web-app   In all the above URLs there is date segment. The information of those blogs can be fetched via blog stub like "netflix-will-launch-in-the-netherlands-later-this-year-as-its-international-expansion-slows" so why to use that date part?


I want to help my sister to move from Windows 7 to Linux Ubuntu 14.04.1. When I boot the computer into the bootable USB stick, it just show me :     ------------------------------------------------↓ Then ↓------------------------------------------------  Black background with a underline sign winking _________________________________________ | _                                     | |                                       | |                                       | |                                       | |                                       | |                                       | |                                       | |                                       | |                                       | |                                       | |                                       | _________________________________________   I have tested for Ubuntu 14.04 also, I encounter the same problem. =[  I wonder if Ubuntu 14.04.1 do not support the hardware of Lenovo G470.

I am trying to boot Ubuntu on my computer.  When I boot Ubuntu, it boots to a black screen.  How can I fix this? Table of Contents:


I drove five hours from Michigan to Chicago.       >        I drove for five hours from Michigan to Chicago.       Is there any meaningful difference between these two sentences?

1.Babies need to sleep 18 hours.      2.Babies need to sleep for 18 hours.   Are these sentences different in meaning? As my teacher says, we use "for" to describe "continuous action without a pause".


Could some one tell me how I increase the weight of an order total using  and  module?

Am working on an ecommerce site and am using ubercart module for that. Now am stuck with an issue which is ' if the weight of order total is >=1kg, i want to add an extra 150g to the order total and final amount calculated should include this extra grams aaded. for example if i have an order for a product worth 1kg, in the checkout page the final weight of order is 1.150 kg. but the product weight should not be increased.only the final order has an extra weight added. can anyone help me to solve this issue?  Thanks in advance..


I have researched a lot about it, I made many tests and no success.  Here's what happens:  My database is now "utf8_unicode_ci". I did a simple test to register a name as "Gê" and the tables are accepting normally.  The problem is when I do it from my RegisterUser php file. The results in the table is this: G&ecirc;  My php connection with the database is:  public function openConnection() {      $this->conn = new mysqli($this->dbhost, $this->dbuser, $this->dbpass, $this->dbname);     $this->conn->set_charset("utf8");     if (mysqli_connect_errno()){         throw new Exception("Could not establish connection with database");     } }   PS: I've tried the latin1_swedish_ci format  Edit:  I fixed this using the following htmlentities: $username = html_entity_decode($_POST["username"], ENT_QUOTES, "ISO-8859-5");

I'm setting up a new server and want to support UTF-8 fully in my web application. I have tried this in the past on existing servers and always seem to end up having to fall back to ISO-8859-1.  Where exactly do I need to set the encoding/charsets? I'm aware that I need to configure Apache, MySQL, and PHP to do this — is there some standard checklist I can follow, or perhaps troubleshoot where the mismatches occur?  This is for a new Linux server, running MySQL 5, PHP, 5 and Apache 2.


I've already edited it before posting to make sure it is not a duplicate and users are mistaking it as a duplicate because it has the phrase dark mode in it.   How am I supposed to make it clear that a relevant question that may have some similarity to an existing question, is not a duplicate?

I asked a question regarding a very specific feature of a program and whether or not it works with a larger program.  Within hours someone had marked it with "This question may already have an answer here of a similar question, but not related to my question.  The question I asked IS NOT ADDRESSED in the referred-to question. It's frustrating to spend half an hour putting together an intelligent and specific question, and then have someone mark it as a duplicate (or possible duplicate), which apparently causes people to skip over my question. I haven't received any more responses since the question was flagged.   Two questions:  (1) How do I get this flagging removed and (2) what's the best way to prevent these "helpful" flaggings in the future?


I have a standard form I use that requires an row to be highlighted one of 7 colors when a condition is met in a cell in that row.  The form varies wildly in length.  Currently, I am using conditional formatting for this behavior.  However, every time I delete or add rows, it breaks apart the conditional formatting into 2 pieces.  This causes some issues and "managing the rules" is pretty time consuming.  One thought I had would be to keep the formatting on another sheet in the workbook that I do not edit, and then applying it at the end, if that is possible.  Has anyone found a work around for this?  Is this kind of entire row formatting with color based on one cell possible in a way that does not require conditional formatting?

I have the following annoying problem with Excel 2010. I use Conditional formatting to apply bold formatting to each line of the spreadsheet that meets a condition expressed by a formula. In the "applies to", I write =$A$2:$Q$149, which is the current extent of my spreadsheet. But I want this range to grow with my spreadsheet, i.e., I want the formatting to permanently apply to the whole spreadsheet. Regularly, my "applies to" field is transformed into a complex range, that selects most lines of spreadsheet, but not all, like =$A$2:$Q$138;$A$140:$Q$147. Have you ever encountered such a problem? Is there a solution?


public class OpenFile {   public static void OpenFile() throws IOException {      ArrayList<String> lineList = new ArrayList<String>();      Variablen.desktop = Desktop.getDesktop();     Variablen.fileChooseropen = new FileChooser();     Variablen.fileChooseropen.setTitle("Open File");     Variablen.fileChooseropen.setSelectedExtensionFilter(new FileChooser.ExtensionFilter("TXT Files (*.txt)","*.txt"));     Variablen.fileChooseropen.setInitialFileName("file.txt");     Variablen.file = Variablen.fileChooseropen.showOpenDialog(null);      if(Variablen.file != null) {         Variablen.inputStream = new FileInputStream(Variablen.file);         Variablen.bufferedReader = new BufferedReader(new InputStreamReader(Variablen.inputStream));         Variablen.stringBuilder = new StringBuilder();         String line;         while ((line = Variablen.bufferedReader.readLine()) != null) {             lineList.add(line);         }      }         /**          *  Creating an Array,to save the content and give it to the Textarea          */             String[] linearray = new String[lineList.size()];             lineList.toArray(linearray);             System.out.println(Arrays.toString(linearray));             Variablen.bufferedReader.close();             Variablen.textarea.setText(String.valueOf(linearray));     } }      Caused by: java.lang.NullPointerException       at sample.OpenFile.OpenFile(OpenFile.java:45)       at sample.Controller.ListenOpenFile(Controller.java:14)       ... 54 more

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?


Take a look at the following script:   await Task.Run(() =>  {                      //Importing data from OMDB                     WebClient OMDB = new WebClient();                     string ReqURL = "http://www.omdbapi.com/?t=the+revenant&apikey=***";                     var RawData = OMDB.DownloadString(ReqURL);                     var JsonData = JsonConvert.DeserializeObject<csOMDBData.Rootobject>(RawData);                     var OMDBData = JsonData;                     txtReport.text = "Done!"; });   I'm using this script for converting a raw data that I get by an API form OMDB to JSON. After converting, I need to change the text of a label called "txtReport" to "Done!" but I get the "Cross-thread operation in not valid!" error!   I have red all the related posts but couldn't find such a situation (Inside a task)! & because I'm new to Visual C# I don't even understand the solutions. If you can, please edit my script, I will learn by edited script. Thanks a lot...

I have a scenario. (Windows Forms, C#, .NET)   There is a main form which hosts some user control. The user control does some heavy data operation, such that if I directly call the UserControl_Load method the UI become nonresponsive for the duration for load method execution. To overcome this I load data on different thread (trying to change existing code as little as I can)   I used a background worker thread which will be loading the data and when done will notify the application that it has done its work.   Now came a real problem. All the UI (main form and its child usercontrols) was created on the primary main thread. In the LOAD method of the usercontrol I'm fetching data based on the values of some control (like textbox) on userControl.    The pseudocode would look like this:  CODE 1  UserContrl1_LoadDataMethod() {     if (textbox1.text == "MyName") // This gives exception     {         //Load data corresponding to "MyName".         //Populate a globale variable List<string> which will be binded to grid at some later stage.     } }   The Exception it gave was     Cross-thread operation not valid: Control accessed from a thread other than the thread it was created on.   To know more about this I did some googling and a suggestion came up like using the following code  CODE 2  UserContrl1_LoadDataMethod() {     if (InvokeRequired) // Line #1     {         this.Invoke(new MethodInvoker(UserContrl1_LoadDataMethod));         return;     }      if (textbox1.text == "MyName") // Now it wont give an exception     {     //Load data correspondin to "MyName"         //Populate a globale variable List<string> which will be binded to grid at some later stage     } }   BUT BUT BUT... it seems I'm back to square one. The Application again  become nonresponsive. It seems to be due to the execution of line #1 if condition. The loading task is again done by the parent thread and not the third that I spawned.  I don't know whether I perceived this right or wrong. I'm new to threading.  How do I resolve this and also what is the effect of execution of Line#1 if block?  The situation is this: I want to load data into a global variable based on the value of a control. I don't want to change the value of a control from the child thread. I'm not going to do it ever from a child thread.   So only accessing the value so that the corresponding data can be fetched from the database.


In the changing password I'm suggested to navigate to the My Login page. After logging on I`m unable to locate this page or Edit Settings.

How do I change my password?  I have a Stack Exchange account but can't seem to find the option to change my password.  Help please?


I find one of the most interesting bits of SE is the "Hot Questions" and often check it 2-3 times a day on my PC and click though to the various sites to see what's happening. I frequently visit SO on my mobile, usually when I'm bored, just to pass the time of day - whilst waiting for the kettle to boil for example - although I rarely answer because it's hard to know the an exact SO answer just using a mobile, but I read the questions and see if there is anything interesting to learn in 5 minutes. Can we have the Hot Questions somewhere in the mobile view, so that there is more interesting content that you can just read in the mobile view? EDIT: This is the one I mean:

I have  bookmarked on my phone but unlike the rest of SE it isn’t responsive. Conscious choice or just overlooked?


I have to show that the set: $$M :=\{f\in C[0,1]:\exists L \gt 0 \: \forall x,y \in [0,1] \space \space \space |f(x)-f(y)| \leq L|x-y| \} $$ is dense in $(C[0,1],|| \cdot|  |_\infty)$  Any ideas?  Thanks in advance.

In $C[0,1]$ prove that the subset of Lipschitz functions is dense. I can't prove it.


The full question is  Prove that if G is a cyclic group with more than 2 elements, then there always exists an isomorphism ϕ:G→G that is not the identity mapping.I have no idea where to start?

Given two isomorphic groups G and H, is it possible that two or more functions define their isomorphism? Also, is it possible that another group say, L is isomorphic to G but not to H?


I'm trying to prove the Zariski topology on $\mathbb A^2$ is not the product topology on $\mathbb A^1\times \mathbb A^1$.  I'm looking for a counter-example based on the fact the closed subsets in $\mathbb A^1$ are the finite ones.  Thanks in advance

Could you please give a hint how to show that the zariski topology on $\mathbb{A}^2$ is not the product topology on $\mathbb{A}^1\times\mathbb{A}^1$


Calendar calendar = new GregorianCalendar(2015, 2, 1); Calendar calendar1 = calendar; Calendar calendar2 = (Calendar)calendar.clone(); System.out.println("calendar == calendar1 is " + (calendar == calendar1)); System.out.println("calendar == calendar2 is " + (calendar == calendar2)); System.out.println("calendar.equals(calendar2) is " + calendar.equals(calendar2));   displays:  calendar == calendar1 --------------> gives you "true"  calendar == calendar2 --------------> gives you "false"  calendar.equals(calendar2) ---------> gives you "true"  My Question:   When you set two objects equal to each other using "==", are you trying to find whether their memory address are equal to each other? I apologize for the confusion. Perhaps I am not understanding what is being compared and equal here? Thank you so much for all your help.

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


I've often just assumed   $$\langle x|p\rangle = \frac{1}{(2\pi\hbar)^{1/2}}e^{ipx/\hbar}$$  Is there a formal way to prove this?  My guess is that, since $\langle x|x'\rangle = \delta(x'-x)$, and a summation of wavepackets is essentially a delta function, we can prove the result starting from the definition of the delta function.

I'm curious whether I can find the overlap $\langle q | p \rangle$ knowing only the following:   $|q\rangle$ is an eigenvector of an operator $Q$ with eigenvalue $q$. $|p\rangle$ is an eigenvector of an operator $P$ with eigenvalue $p$. $Q$ and $P$ are Hermitian. $[Q,P] = i \hbar$.   I'm asking because books and references I've looked in tend to assume that $Q$ is a differential operator when viewed in the $P$-basis, then show that it satisfies the commutation relation. (I haven't read one yet that proves that the form given for $Q$ is the only possible one.) I've heard, though, that we can work purely from the hypothesis of the commutation relation and prove the properties of $Q$ and $P$ from it.


First and foremost request is that if you find this to be a duplicate request, please, guide me to the correct page.  I tried few solutions but none worked. May be I'm doing something silly. Anyway, I'm stuck with something.  Here's my XML format:  <Root> <MainFolder Name="Main">     <Folder Name="Folder1">         <Folder Name="SubFolder1">             <File />             <Folder Name="SubFolder2">             </Folder>         </Folder>     </Folder>     <Folder Name="Folder2">         <Folder Name="SubFolder3">             <File />         </Folder>     </Folder> </MainFolder> </Root>   The thing is that I want to traverse through the XML and show the Name attribute value for all Folders tag.  As of now, I'm just able to search and show results for only "Folder1" and "Folder2". I'm not to traverse through subfolders.  Please, help me with this. Thanks in advance.  Sample of the code I'm using currently:  XElement root = XElement.Load("File.xml"); var mainFolder = root.Element("Main"); foreach (var folder in mainFolder.Elements("Folder")) {     folderName[noOfFolders] = folder.Attribute("Name").Value;     MessageBox.Show(folderName[noOfFolders]);      foreach (var file in folder.Elements("File"))     {      ...     }  }   Please, let me know if you guys need more info.

I have an XDocument object. I want to query for elements with a particular name at any depth using LINQ. When I use Descendants("element_name"), I only get elements that are direct children of the current level. I'm looking for the equivalent of "//element_name" in XPath...should I just use XPath, or is there a way to do it using LINQ methods?


i have been created 'job' content type, i used 'Devel module' to generate content of 'job' type, but in some 'jobs' its taking anonymous user as a author, but i don't want anonymous user as author, so what should i do to avoid anonymous user as a author?

I'm using Devel's generate content feature to generate Blog/Forum entries for a site I'm working on and funny enough, I get to have a blog post by an anonymous user or forum topic by an anonymous user.  How can I stop Devel from doing this? I've only given Authenticated Users/ Administrators the permission to create a blog post or forum topic but still it generate for anonymous user. How can correct this?


I am doing an prison escape map and i want to make an crowbar to destroy only iron trapdoors and is named crowbar. How???

I'm trying to create an item that can break certain blocks, but also has a colored name in 1.13.2   Here's the command I'm using.  /give iAugust minecraft:shears{display:{Name:"[{\"text\":\"Arcane Shears\",\"color\":\"aqua\",\"italic\":false,\"bold\":false}]CanDestroy:[minecraft:iron_bars]"}}   But it only has a colored name, and it can't break specific blocks.


The current behavior when using \underbrace is the following (Tex inserts whitespace to avoid streching the text underneath the underbrace beneith the neighboring symbols):   The behavior I want instead is the following:   How can this be achieved?  EDIT: The code I used for this image is  as follows  Y_{2,2}(\theta,\varphi) - Y_{2,-2}(\theta,\varphi) = \dfrac{2i}{\sqrt{4\pi}}\sqrt{\dfrac{15}{8}} \underbrace{\sin^2\theta\sin(2\varphi)}_{=\frac{1}{2}\sin^2\theta\sin\varphi\cos\varphi={\frac{1}{2}d_{xy}/C_{xy}}}

Consider this:  \left( x-1 \right) \underbrace{ \left( ? \right) }_{ \text{what is this?} }   The label is longer than the braced portion, which causes unwanted space between the parentheses.  Is there a way around that, so that the parentheses "touch" as they would normally?  Please note that I just started on LaTeX, and I'm using TexMaths inside LibreOffice Writer.


I wrote a bash script to change my wallpaper automatically on Ubuntu 20.04 and it works well, but when I'm trying to automate it with crontab it doesn't work, the wallpaper isn't changing. Here is my script : #!/bin/bash DIR="/home/mbz/Wallpapers" PIC=$(find $DIR -type f -maxdepth 1 2>/dev/null | shuf -n1) gsettings set org.gnome.desktop.background picture-uri "file://$PIC"  after typing crontab -e, i put in the end of the file the line below to change it very 1mn * * * * * cd /home/mbz/Desktop/ && bash ba.sh  But, it's not changing the wallpaper !

I have found a guide for that but doesn't sure if it will work or it is safe to use. The guide:  I am asking if is these introductions safe and will work? If not, is there any other solutions for that? I am using Ubuntu 20.04 LTS Thank you.


Let $a, b ,n \in Z$ with $n > 0$ and $a \equiv b \pmod n$.  Show that $\gcd(a,n) = \gcd(b,n) = d$.  I tried rewriting $b = a + ny$ for some $y \in Z$. Now if I have $d \mid a$ and $d \mid n$, then $d \mid b$. However I don't know how to continue.

If $ b\equiv c \pmod m $ then prove that $(b,m)=(c,m)$.  My solution so far:     If $b \equiv c \pmod m$ then $c = b - sm$ for some $s$. Now if $d = (b, m)$ then $ d |  (b + s m)$.


Yeah, this hasn't been patched since 2012 [ ]

In the , the Ask Ubuntu logo is shown as:  when indeed it should have the "speech-bubble" portion visible. Looking at the image carefully shows that it should(if I am correct) be transparent around the white speech bubble, which isn't visible at all. Some users, as seen in comments below, believe that the icons from the  should be used, which I agree with. I wasn't sure whether this belongs here because it is about the design of the data explorer, or on Ask Ubuntu meta because of the logo design, so feel free to migrate if it is in the wrong place.


I'm making a Linux installer for Zero-K, an open source RTS game (zero-k.info). It will use zenity for dialogs but for that zenity must be installed. As plenty of people will not already have zenity it must be installed by the script.   I would not like to install something on a user's system without a terminal opening and giving some feedback. If there was no feedback it may look like nothing was happening when it is actually busy installing things. The problem is that the script would have to open xfce4-terminal or gnome-terminal or another DE specific terminal, meaning that there will have to be a different script per DE.   Is there a command to open whatever terminal is used by the OS/DE that the script is used on?

Say I need to write a script that will launch a terminal and execute a command and I need that to work on various systems. How can I do that in a safe and portable manner?  Is xterm always installed? I assume that any *nix with a GUI must have some terminal emulator. How can I get to it? Debian systems  x-terminal-emulator but that, apparently,  in Red Hat, let alone non-Linux *nixes.


I have a server running for which I want to have a possility to access it with a screen connected to VGA (very rarely, most of the time it's accessed via SSH). Therefore I have a PCI-e graphic cards plugged in and the VGA cable removed. The graphic card is passively cooled and if I open the case and touch the cool body I can feel a noticable warmth and conclue that it's consuming energy (there're no consumers close to it that could transmit the thermal energy in any way).  If I unplug the card (as suggested in ) I have to built it in every time I want to connect a screen. I would like to avoid that as well as the energy consumption.  The de- and re-activation needs to take place on the OS level (e.g. via SSH) because otherwise I'd need a screen to configure the UEFI (or do that blindly which is no alternative) and run into a chicken-egg-problem.  I'm using Ubuntu 15.04 with Linux 4.0.2. The graphic card is labeled XFX HD 5450 850M and has a VGA, HDMI and D-SUB connector. The mainboard is an ASRock X99-Extreme without integrated graphic.  EDIT: After blacklisting used modules listed in sudo lspci -v (following @WhimsicalWombat's promising answer below) (in my case I had to use the modprobe.blacklist=module_to_blacklist kernel parameter - see  for more details - for radeon and snd_hda_intel) the PCIe graphic card still heats up (passive cooler has > 60 degrees and there's no heat source closeby) and no modules are listed in lspci -v for the devices. The output of lspci -v for the devices is not   01:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Cedar [Radeon HD 5000/6000/7350/8350 Series] (prog-if 00 [VGA controll er])         Subsystem: XFX Pine Group Inc. Device 303e         Physical Slot: 4         Flags: bus master, fast devsel, latency 0, IRQ 11         Memory at e0000000 (64-bit, prefetchable) [size=256M]         Memory at fbe20000 (64-bit, non-prefetchable) [size=128K]         I/O ports at e000 [size=256]         Expansion ROM at fbe00000 [disabled] [size=128K]         Capabilities: [50] Power Management version 3         Capabilities: [58] Express Legacy Endpoint, MSI 00         Capabilities: [a0] MSI: Enable- Count=1/1 Maskable- 64bit+         Capabilities: [100] Vendor Specific Information: ID=0001 Rev=1 Len=010 <?>         Capabilities: [150] Advanced Error Reporting  01:00.1 Audio device: Advanced Micro Devices, Inc. [AMD/ATI] Cedar HDMI Audio [Radeon HD 5400/6300 Series]         Subsystem: XFX Pine Group Inc. Device aa68         Physical Slot: 4         Flags: bus master, fast devsel, latency 0, IRQ 10         Memory at fbe40000 (64-bit, non-prefetchable) [size=16K]         Capabilities: [50] Power Management version 3         Capabilities: [58] Express Legacy Endpoint, MSI 00         Capabilities: [a0] MSI: Enable- Count=1/1 Maskable- 64bit+         Capabilities: [100] Vendor Specific Information: ID=0001 Rev=1 Len=010 <?>         Capabilities: [150] Advanced Error Reporting   EDIT 2:  suggests to do echo 0 > /sys/bus/pci/slots/$N/power and I have a /sys/bus/pci/slots/$N where $N is number of the slot listed in lspci -v, but there's no power file.  EDIT 3: adding the modaliases of /sys/bus/pci/devices/[device]/modalias to modprobe.blacklist= kernel parameters has no effect on Ubuntu mainline kernels from  and a custom 4.0.5 build with make localmodconfig and activation of all PCI options causes the "Loading initramfs [version]" screen to remain visible for ever while the graphic card is still heating up.

I'm looking at building a system that supports VT-d so I can pass through a high powered loud video card to a Xen/KVM/whatever VM (host will be Linux based).  However, when I'm not using the VM I want to turn the video card off so its fan does not run.  The card will not be used when the VM isn't running.  Anyone know if this is possible?  The PCI-Express hot-plug specification allows cutting power to specific slots but I have never heard of anyone doing it with a video card and my searches for information have turned up nothing.


is there a method to store the settings of background images? I use them often as modeling reference in the viewport, but everytime I open up the blend-file all settings are gone:   Settings during work   Settings after restart  As long as you get the modeling done without a restart or changing the files, there is no problem. However it's annoying to replace all images over and over again.  Any ideas?

I have seen a single (1) mention of View port background images disappearing when the .blend file is saved and reopened.  However...the answers are not relative to what I am experiencing.  I go through the trouble of setting up four images (top, side, front, back) and then pack these images using External Data > Pack all into .blend and then I save the .blend.  I save the file, open it back up, and the background images are all gone. Open up properties panel, look to see background images check box is unchecked, click add image, and choosing the open drop-down arrow...the data paths still show the list of images (packed into a specific folder textures).  They are still there, the data set is intact.  Why is It that I have to set this up each and every time I open the file.  It seems like earlier versions <2.76B saved the images and saved the file with the background images check box checked without the need to set this up each time the file is reopened.  This is getting very frustrating due to the fact that a few of the background images mus be set up using Blender's rotate, scale and move tools to align the background image up with the model I have already fabricated.  Thanks!


I have to implement a threadsafe logging mechanism in C++ under Windows and I want to use the streams library.  I wanted to know if anyone could give me some advice regarding doing this and what would be the best way?  The logging messages will most likely be a few lines long each time, so I'd probably need to write them to a buffer first and then flush to file?  This logging should be fairly fast and not affect the performance of the application too much when its used, so I was thinking of doing the actual writing to the file in its own thread.  Is that a good idea?  Any advice and hints are appreciated.

I am working on a performance critical multi-threaded application. I looked at rlog, Ace and Boost logging. I chose rlog because I read it was the fastest (when logging is disabled, it has the least overhead).  The problem I have is it shows the file name, line number etc. even in release mode. If you can tell me how to shut that information off, my problem might be solved. In any case what is the most efficient logger in C++ for my situation?


The way the Similar Questions pane "writes over" the footer is not behavior I would expect. Is that correct behavior?

I have noticed that while asking questions and scrolling to the bottom of the page, the right sidebar containing recent questions covers the footer partially. Also, a part of it goes beyond the browser's boundary. It may not be a big problem but it still doesn't look good.    This also happens on the  page


I have a Dell with a Core I5 and a GeForce820M.  After upgrading to 18.04 LTS I tried to upgrade the nvidia drivers by running  sudo apt-get install nvidia-340   which is the recommended driver for my GPU.  The problem is the installation failed, I didn't record the fail reasons and now any dpkg or apt-get commands I try to run say that I should run   sudo dpkg --configure -a    I tried running that but it kept getting stuck at   Building initial module for 4.15.0-23-generic   Finally I managed to complete it, but when I tried to install the nvidia-340 package again I got an error:  Preparing to unpack .../nvidia-340_340.106-0ubuntu3_amd64.deb ... Adding 'diversion of /usr/lib/x86_64-linux-gnu/libGL.so.1 to /usr/lib/x86_64-linux-gnu/libGL.so.1.distrib by nvidia-340' dpkg-divert: error: rename involves overwriting '/usr/lib/x86_64-linux-gnu/libGL.so.1.distrib' with   different file '/usr/lib/x86_64-linux-gnu/libGL.so.1', not allowed dpkg: error processing archive /var/cache/apt/archives/nvidia-340_340.106-0ubuntu3_amd64.deb (--unpack):  new nvidia-340 package pre-installation script subprocess returned error exit status 2 Errors were encountered while processing:  /var/cache/apt/archives/nvidia-340_340.106-0ubuntu3_amd64.deb E: Sub-process /usr/bin/dpkg returned an error code (1)

I got a strange error after upgrading Ubuntu 16.04 to 16.10.  The Software Updater suggests a partial update:     Could not install 'systemd-shim'      The upgrade will continue but the 'systemd-shim' package may not be in a working state. Please consider submitting a bug report about it.  subprocess installed post-removal script returned error exit status 2    sudo apt-get update finishes without any error.  sudo apt-get remove outputs this  The following packages will be REMOVED:   systemd-shim 0 to upgrade, 0 to newly install, 1 to remove and 0 not to upgrade. 1 not fully installed or removed. After this operation, 71.7 kB disk space will be freed. Do you want to continue? [Y/n] y (Reading database ... 1451244 files and directories currently installed.) Removing systemd-shim (9-1bzr4ubuntu1) ... Removing 'diversion of /usr/share/dbus-1/system-services/org.freedesktop.systemd1.service to /usr/share/dbus-1/system-services/org.freedesktop.systemd1.service.systemd by systemd-shim' dpkg-divert: error: rename involves overwriting '/usr/share/dbus-1/system-services/org.freedesktop.systemd1.service' with   different file '/usr/share/dbus-1/system-services/org.freedesktop.systemd1.service.systemd', not allowed dpkg: error processing package systemd-shim (--remove):  subprocess installed post-removal script returned error exit status 2 Errors were encountered while processing:  systemd-shim E: Sub-process /usr/bin/dpkg returned an error code (1)   Please help me to fix this error. Thank you.


With the axiom of choice, we can select a ration number $r_k$ in each interval $[a_k,b_k]$ and we can easily prove $Q$ is countable,so this complete the proof.  However,without the axiom of choice, does each interval has a rational number which we can select?

There are several proofs I have seen of this, but they all seem to use choice subtely at some point. Is there any way to prove this without choice, or is it possibly unproveable?


I am currently developing a plugin, which depends on another plugin (json-api). I use the following code to check for the presence during startup and in the constructor, in case the json-api plugin is deactivated later on:  require_once (ABSPATH . '/wp-admin/includes/plugin.php');  class MyPlugin {     public function __construct() {         // ...          // register a check for dependency         add_action('plugins_loaded', array( $this, 'dependency_check' ));      }      public function dependency_check() {         if (!class_exists('DEP_CLASS'))             $this->dependency_failed();     }      protected function dependency_failed() {         if (current_user_can( 'activate_plugins' ))             deactivate_plugins( plugin_basename ( __FILE__ ) );          add_action('admin_notices', array ($this, 'notify_dependency_problem') );     }      public static function notify_dependency_problem() { /* ... error message shown ... */ }      public function activate() {         if (!is_plugin_active('dep_plugin/start.php')) {             $this->dependency_failed();             return false;         }     } }  register_activation_hook(__FILE__, array('MyPlugin', 'activate')); new MyPlugin();   This works fine so far - however, Wordpress additionally shows a "Plugin Activated" notice, which is misleading to the user. Additionally, the buttons ("Activate", "Edit", "Delete") below the plugin are now missing as well.   How is it possible to get rid of the "Plugin Activated" Message (Note: Thanks to @toscho, this has been resolved via a unset($_GET['activate'])) and  how to get the buttons back?

I'm making a WordPress plugin. What are typical things I should include in the uninstall feature?  For example, should I delete any tables I created in the install function?  Do I clean up my option entries?  Anything else?


I have this image that I got from slidesjs.com  It looks awesome when used as a frame, but I want to "elongate" it. Steps on how to accomplish this? I know it looks like a simple shadow, but the bottom shadow is darker. This is similar to this image:  Maybe someone has a link to a tutorial? I'm really focused on the frame though as the dark color isn't as apparent. It's more subtle. Another reason why I want to do this, is that I want to change the shadow color.

I'm working on a mockup of a jQuery slider which can be found .   Now, I'm not the best graphic designer by any stretch of the imagination, and I can't seem to be able to get a realistic looking shadow. What I want is for the phone to appear as if it's standing on its side, but all of my attempts in Photoshop usually result in the phone looking like it's floating at a weird angle.  What I've tried so far (and failed at):   Added an elipse near the bottom of the phone and blurred it. This sorta worked but just doesn't look right. Added a rectangle and did the same as the previous bullet, but this looked worse. Tried using a drop shadow layer effect. This looked horrible.   Can anyone give me some suggestions?


I am trying to create a method which retrieves contact name for the given input string. For that I have to use getContentResolver method. To use the context I am passing the context as the parameter. But still the following error is populating.     java.lang.NullPointerException: Attempt to invoke virtual method   'android.content.ContentResolver   android.content.Context.getContentResolver()' on a null object   reference   public class GetContactName {      public static String getContactName(Context context, String phoneNumber) {         Uri uri = Uri.withAppendedPath(ContactsContract.PhoneLookup.CONTENT_FILTER_URI, Uri.encode(phoneNumber));          String[] projection = new String[]{ContactsContract.PhoneLookup.DISPLAY_NAME};          String contactName = "";         Cursor cursor = context.getContentResolver().query(uri, projection, null, null, null);          if (cursor != null) {             if (cursor.moveToFirst()) {                 contactName = cursor.getString(0);             }             cursor.close();         }          return contactName;     }  }   Please help me to solve this

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 had come across  answer to  question. In one of the line, the author mention's:     In any case, follow the guideline "prefer ++i over i++" and you won't go wrong.   I know that ++i is slightly faster than i++, but thought that there is no reason for them to go wrong. I searched for a while, and the closest I could get to was . It explained clearly that why is it preferred to use ++i, but not still how could you go wrong using i++.  So can anyone tell me how can i++ go wrong?    NOTE: My question isn't a dupe, as I am not asking about the performance. I have already seen that question. I am asking how can i++ be wrong as mentioned in the answer I have mentioned above.

Is there a performance difference between i++ and ++i if the resulting value is not used?


I have used vi as my main text editor for years now on Linux (and a few years back Mac too) and on my brand new Mac (running 10.8.4) I find when trying to edit a file using vi in Terminal I can not use the standard vi shortcuts e.g. using 'CTRL + E' to navigate to the end of a line. Instead the shortcut is set to the vim shortcut which is '$' to navigate to the end of a line. I a using bash. How can I get the standard vi shortcuts?

I'm trying to switch to MacVim as my main editor, and I'm liking it so far, except for one issue:  I got really used to the Mac shortcuts control-A to go to the beginning of a line, and control-E to go to the end of a line.  However, these two don't work in MacVim (control-A does something weird -- it seems to increase the last number in a line by 1 or something, and control-E seems to scroll down the screen by one line).  Any way to make these two shortcuts go to the beginning of a line / end of a line respectively instead?


When I'm trying to upload photos in Blender-General using Import in File, its not working. The square outline of the image is coming but not the actual picture itself so i end up with a blank rectangle. Can anybody tell me if there is any way to fix this?

I have added some textures to objects in blender but the textures don't show up until I render the file. it can be difficult to know what the objects look like without rendering it. is there a way to have textures show in the editor even if they are at a lower res?  In editor:    Rendered:


Is there any reference that contains this proof: Show that if $M$ is projective then $\operatorname{Hom}_R(M,.)$ is an exact functor. Or any help in the proof will be appreciated. We defined projective module as follows: An $R$-module $P$ is projective if, whenever $A,B$ are $R$-modules, $f \in \operatorname{Hom}_R(P,B),$ and $g \in \operatorname{Hom}_R(A,B),$ is surjective, there exists $\tilde{f} \in \operatorname{Hom}(P,A)$ such that $f = g \tilde{f}.$ And I proved that the $\operatorname{Hom}_R(M, -)$ functor is a left exact functor. Also, I have proved if $P$ is free then $P$ is projective. Any help will be appreciated. EDIT: I already solved this problem: $(a)$ Let $P$ be an $R$-module. Show that the following three conditions are equivalent.\ 1.$P$ is projective.\ 2. Any surjective homomorphism $g: A \rightarrow P$ of $R$-modules has a section.\ 3. $P$ is a direct summand of a free module, i.e.,there is a free $R$-module $F$ and submodule $Q$ such that $F = P \oplus_R Q.$\ $(b)$ Part $(a)$ shows that, if $P$ is free, then $P$ is projective. Give an example of a finitely generated projective module which is not free.\

I'm working in the categories of $A$-modules. I'm trying to prove that $\hom(P,\cdot)$ is an exact functor $\iff$ $\exists\,Q$ such that $P\oplus Q$ is a free $A$-module.  I'm having trouble translating the property of "freeness" into the preservation of exact sequences (and vice-versa). They still seem like totally different things to me.   Any tips?


I do not want users to be able to add comments to each row of my SharePoint lists. How do I turn this feature off?

Anyone know how to turn this OFF? I use my own field to track comments in our document approval system, this new feature confuses users. This icon appears in custom lists:    PS: And what is this?


I want to model the earth 1:1 in unity, but I can only zoom to a certain value in the scne window of unity

Does Unity have a map size limit and if there is what is the limit? Is there a way to work around it? I am making a open world zombie survival world and I want to make a really big map. Thanks!


Let X be a single observation form the uniform distribution:  f(x) is a piece wise function where f(x)= $\frac{1}{\theta}$ if $0<x<\theta$ and $0$ otherwise.  Suppose we use (X, 1.5X) as a confidence interval for $\theta$. What is the confidence level.  I thought I could backwards engineer this by letting $X = x- z_\frac{\alpha}{2} \frac{\sigma}{\sqrt n}$ and $1.5X = x+ z_\frac{\alpha}{2} \frac{\sigma}{\sqrt n}$ but it doesn't work out, how do I go about this question?

I am studying for my upcoming stats final exam and I come across this question:  Let X be a single observation from the uniform distribution:   $$f(x) = \begin{cases}       0 & \text{otherwise} \\       \frac{1}{\theta} &  0 ≤x ≤ \theta \end{cases}$$  Suppose we use $(X, 1.5X)$ as a confidence interval for $\theta$. What is the confidence level?  I have no idea how to start.  Since I am given a confidence interval, I believe I need to integrate the function from $X$ to $1.5X$, but I'm not sure what to do next, should I even integrate.  How can I solve this problem?


I am looking for Melbourne shape file map (boundaries or suburbs or roads). Just for Melbourne.   Any one knows where I can download it?

I am looking for shapefiles or a list of suburb names for Melbourne and Canberra. I have ABS shapefiles, but I need to filter that to end up with only metropolitan suburbs.  My shapefile has codes in it for  - I just need to know which suburbs belong to the metros.


I got the basic structure:  <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8">   and the input:  <input type="text" name="var"/>   to get with:  $var = iconv('UTF-8', 'ASCII//TRANSLIT', $_POST['var']); //or $var = $_POST['var'];   and show like:  echo $var; //or print_r($var); //or print_r(iconv('UTF-8', 'ASCII//TRANSLIT', $var));   i try force a new header:  header('Content-type: text/html; charset=utf-8');   and with .htaccess:  AddDefaultCharset UTF-8   and nothing works :( The only things that appears is: jos? instead josé  how solve it?

I'm setting up a new server and want to support UTF-8 fully in my web application. I have tried this in the past on existing servers and always seem to end up having to fall back to ISO-8859-1.  Where exactly do I need to set the encoding/charsets? I'm aware that I need to configure Apache, MySQL, and PHP to do this — is there some standard checklist I can follow, or perhaps troubleshoot where the mismatches occur?  This is for a new Linux server, running MySQL 5, PHP, 5 and Apache 2.


I know there are a lot of questions on this already. I have tried the solutions from those, they don't work. I'm writing my thesis in the report class. The first few pages are roman numerals and everything after the list of figures should be arabic numbers. However, the second page of list of figures is numbered as 1. The Preface is numbered 2 but shows up in the ToC as 1. Here's a MWE:  \documentclass{report} \usepackage[utf8]{inputenc} \usepackage{geometry} \geometry{letterpaper, margin = 1in} \usepackage{pdfpages, subfiles} \begin{document} \subfile{Others/cover} \subfile{Others/Quote}  \pagenumbering{roman}  \addcontentsline{toc}{chapter}{Acknowledgements} \subfile{Others/Acknowledgements}  \tableofcontents  \addcontentsline{toc}{chapter}{List of Figures} \listoffigures  \pagenumbering{arabic} \addcontentsline{toc}{chapter}{Preface} \subfile{Others/Preface} \subfile{Sections/Introduction} \end{document}   Please suggest what I can do to fix the pagenumbering and have it show correctly in the ToC. Thanks!

In my Master thesis, I would like to have the title page without any page number and an acknowledgments section and the table of contents with roman numbers. The rest of the document should be numbered arabic.  I have tried this, to have roman numbers for the Table of contents and normal numbers for the rest.  \documentclass[12pt,ngerman,openany]{report} \usepackage{titlesec} \usepackage{titletoc} \usepackage{cite} \usepackage[a4paper]{geometry} %\usepackage[T1]{fontenc} \usepackage[utf8]{inputenc} \usepackage[ngerman]{babel} %\usepackage{ngerman}{babel} \usepackage[T1]{fontenc} \usepackage{graphicx} \usepackage{float} \selectlanguage{ngerman} \usepackage{amssymb} \usepackage{amsmath} \usepackage{url} \usepackage{epstopdf} \usepackage{scrhack} \usepackage{listings} \usepackage{caption} \titleformat{\chapter}{\rmfamily\huge}{\textbf\thechapter.}{25pt}{\huge\textbf} \defcaptionname{ngerman}{\lstlistingname}{Code} \defcaptionname{ngerman}{\lstlistlistingname }{Codeverzeichnis}  \lstloadlanguages{R}  \lstset{% general command to set parameter(s)    basicstyle=\sffamily\footnotesize, % print whole listing small    keywordstyle=\sffamily\footnotesize\bfseries, % ubold black keywords    identifierstyle=, % nothing happens    commentstyle=\sffamily\footnotesize\slshape, % green comments    stringstyle=\sffamily\footnotesize, % typewriter type for strings    showstringspaces=false, % no special string spaces    numbers=left,    numberstyle=\sffamily\footnotesize,    stepnumber=1,    numbersep=10pt,    showspaces=false,    showtabs=false,    frame=lines,    morecomment=[l]{\%},    float=htbp,    numberbychapter=true  }   \begin{document} \let\cleardoublepage\clearpage   \pagenumbering{roman}  \tableofcontents  \clearpage  \vspace*{75mm} \chapter{Einleitung} \section{Motivation} bla bla bla \section{Ziel}  bla bla \chapter{Stand der Technik zur Mustererkennung} \section{Die Zeitreihen} bla bla \subsection{Beschreibung} bla bla \subsection{Erklärung}  bla bla  \subsection{Vorhersage} bla bla \subsection{Kontrolle} bla bla \section{Feature Extraktion} bla bla \subsection{Autokorrelation} \subsection{Was ist Autokorrelation?} bla bla   \subsection{Autokorrelation und Zeitreihen} bla bla  \subsubsection{Zeitreihe-Diagramm}  bla bla \subsubsection{Lagged Streudiagramm} bla bla  \subsubsection{Autocorrelation-Function (Korrelogramm)} bla bla \subsection{Spektralanalyse} \subsection{Was ist Spektral-Analyse} bla bla \end{document}


A rubber ball was dropped from a height of 36m. and each time its strikes the ground it rebounds to a height of 2/3 from which it last fell. Find the total distance traveled by the ball before it comes to a rest.  Answer according to reviewer is 180m  I applied geometric series  $${ \sum_{i=0}^\infty {36\times\left( \frac{2}{3} \right)^i } = 108}$$  well actually I put 250 on the calculator instead of infinity but nonetheless it stays lke that. Is it possible problem set is wrong?

This is kind of an odd question, but can somebody please tell me that I am crazy with the following question, I did the math, and what I am told to prove is simply wrong:  Question: Show that a ball dropped from height of h feet and bounces in such a way that each bounce is $\frac34$ of the height of the bounce before travels a total distance of 7 h feet.  My Work: $$\sum_{n=0}^{\infty} h \left(\frac34\right)^n = 4h$$  Obviously 4 h does not equal 7 h .  What does the community get?  I know that my calculations are correct, see Wolfram Alpha and it confirms my calculations, that only leaves my formula, or the teacher being incorrect...  Edit: Thanks everyone for pointing out my flaw, it should be something like: $$\sum_{n=0}^{\infty} -h + 2h \left(\frac34\right)^n = 7h$$  Thanks in advance for any help!


By default if you write order by it is considered as ascending order and if you want like highest to lowest use as: order by desc. But my question is how to sort two things like I have name and class (VarChar) both how can i sort them both? Please help. I am using MySQL query: select name,class from student order by name asc, class asc; but it's not showing what I want. Data is like: name: Mike class: Four select name,class from student order by name asc, class asc;

How do I sort a MySQL table by two columns? What I want are articles sorted by highest ratings first, then most recent date.  As an example, this would be a sample output (left # is the rating, then the article title, then the article date)  +================+=============================+==============+ | article_rating | article                     | article_time | +================+=============================+==============+ | 50             | This article rocks          | Feb 4, 2009  | +----------------+-----------------------------+--------------+ | 35             | This article is pretty good | Feb 1, 2009  | +----------------+-----------------------------+--------------+ | 5              | This Article isn't so hot   | Jan 25, 2009 | +================+=============================+==============+  The relevant SQL I'm using is: ORDER BY article_rating, article_time DESC  I can sort by one or the other, but not both.


I know literally nothing about linux/ubuntu, but I have linux activated and I downloaded it through steam. When I click on it to open it it gives me the message: You are missing the following 32-bit libraries, and Steam may not run: libc.so.6 Could someone help?

I've already installed Steam, but when I click on the program I get this message  ERROR- You are missing the following 32-bit libraries, and Steam may not run: not   I don't know what to install or even do.


Is there a prime number $p$, such that $\mathbb{Q}_p$ is isomorphic to a subfield of $\mathbb{C}$?

A few days ago I was recalling some facts about the $p$-adic numbers, for example the fact that the $p$-adic metric is an ultrametric implies very strongly that there is no order on $\mathbb{Q}_p$, as any number in the interior of an open ball is in fact its center.  I know that if you take the completion of the algebraic closure of the $p$-adic completion you get something which is isomorphic to $\mathbb{C}$ (this result was very surprising until I studied model theory, then it became obvious).  Furthermore, if the algebraic closure is of an extension of dimension $2$ then the field is orderable, or even real closed. Either way, it implies that the $p$-adic numbers don't have this property.  So I was thinking, is there a $p$-adic number whose square equals $2$? $3$? $2011$? For which prime numbers $p$? How far down the rabbit hole of algebraic numbers can you go inside the $p$-adic numbers? Are there general results connecting the choice (or rather properties) of $p$ to the "amount" of algebraic closure it gives?


I want create some console application. This application will work by parameters from input args[] array.   Like this: > app.exe -arg1 -arg2 -arg3:str3 -arg4:str4 -arg5 etc.  Where -arg1, -arg2, -arg5 the parameters for initialization variables in my app. The -arg3:str3 and -arg4:str4 the parameters with any string.  For example, if I sent the -arg1 then in my app I need initialization the var1 by any string. Like this:  foreach (string s in args) {     if(s.contains("-arg1")) someString1 = "someVal1";     if(s.contains("-arg2")) someString2 = "someVal2";     if(s.contains("-arg5")) someString5 = "someVal5";     if(s.contains("-arg3")) someString3 = s.split(':')[1];     if(s.contains("-arg4")) someString4 = s.split(':')[1]; }   I think that my solution is bad, because I need to test every argument in a loop and if I want to pass more new parameters I have to add new conditions.  Tell me please, maybe there are specific approaches to solving my problem? Or maybe there is some design pattern for such tasks?  EDIT: I can't use any libraries

When building console applications that take parameters, you can use the arguments passed to Main(string[] args).   In the past I've simply indexed/looped that array and done a few regular expressions to extract the values. However, when the commands get more complicated, the parsing can get pretty ugly.    So I'm interested in:   Libraries that you use Patterns that you use   Assume the commands always adhere to common standards such as .


I need to show that if $n$ is not a prime power,then $\mathbb{Z}/\mathbb{nZ}$ admits idempotents $\neq 0,1$   I noticed this thing for $\mathbb{Z_6}$ and $\mathbb{Z_{12}}$ and few more but how do we show that there will always exists such $a$?

An element $a$ of the ring $(P,+,\cdot)$ is called idempotent if $a^2=a$. An idempotent $a$ is called nontrivial if $a \neq 0$ and $a \neq 1$.   My question concerns idempotents in rings $\mathbb Z_n$, with addition and multiplication modulo $n$, where $n$ is natural number. Obviously when $n$ is a prime number then there is no nontrivial idempotent. If $n$ is nonprime it may happen, for example $n=4, n=9$, that also there is no.     Is it known, in general, for what $n$ there are nontrivial idempotents and what is a form of such idempotents?


What is the scope and idea behind Compact Spaces in Topology?  Considering that the basic topics in Topology is covered using the book by Munkres

I've read many times that 'compactness' is such an extremely important and useful concept, though it's still not very apparent why. The only theorems I've seen concerning it are the Heine-Borel theorem, and a proof continuous functions on R from closed subintervals of R are bounded. It seems like such a strange thing to define; why would the fact every open cover admits a finite refinement be so useful? Especially as stating "for every" open cover makes compactness a concept that must be very difficult thing to prove in general - what makes it worth the effort?  If it helps answering, I am about to enter my third year of my undergraduate degree, and came to wonder this upon preliminary reading of introductory topology, where I first found the definition of compactness.


I need to validate a password entry on a textbox, I have a few demands to fullfill in order to allow the user profile to be created and one of them is to refuse registration if the password contains anything else different than numbers and the alphabet letters the system needs to deny the entry, everything I tried seems to fail. Here is where I'm standing right now:       private void BUT_Signup_Click(object sender, EventArgs e)     {      string allowedchar = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789";      if (!(TXT_NewPassword.Text.ToString().Contains(allowedchar)))                     MessageBox.Show("No special characters on the password are allowed");

I have a windows forms app with a textbox control that I want to only accept integer values. In the past I've done this kind of validation by overloading the KeyPress event and just removing characters which didn't fit the specification. I've looked at the MaskedTextBox control but I'd like a more general solution that could work with perhaps a regular expression, or depend on the values of other controls.  Ideally this would behave such that pressing a non numeric character would either produce no result or immediately provide the user with feedback about the invalid character.


I'm typesetting a series of documents with the article class which present a series of problems with figures and/or tables, using the amsthm package. There are no sections in the document. What I'm aiming to do is to number each figure and table by the problem number, followed by the figure/table number. For example, the 3rd figure in the 4th problem would be numbered 'Figure 4.3', and the 2nd table in the 5th problem would be numbered 'Table 5.2'. For this purpose I wrote the following code (trimmed down to a MWE): \documentclass[12pt]{article} \usepackage{amsthm} \usepackage{graphicx} \usepackage{hyperref}  \theoremstyle{definition} \newtheorem{problem}{Problem}  \renewcommand{\thefigure}{\arabic{problem}.\arabic{figure}} % custom figure numbering \renewcommand{\thetable}{\arabic{problem}.\arabic{table}} % custom table numbering \newcommand{\newproblem}{\setcounter{figure}{0} \setcounter{table}{0}} % reset figure and table counter  \begin{document} \title{Minimum Working Example} \author{R. J. Drofnats} \maketitle \begin{problem} Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque quis est at lacus auctor semper sit amet nec orci. Sed ultricies felis aliquam leo auctor aliquet. Vivamus eget metus et ligula aliquet hendrerit vitae ac nisl. Aenean eget diam ut nisi condimentum bibendum. Sed nulla magna, mollis in blandit a, finibus eu risus. Aliquam justo felis, tristique at diam sed, blandit ullamcorper nunc. Mauris non diam et purus convallis dapibus. Morbi eget egestas ligula, ornare cursus odio. See Figure \ref{fig:mwe_1-1}. See also Figure \ref{fig:mwe_1-2}. \begin{figure}[ht]     \centering     \includegraphics[width=0.4\textwidth]{mwe_1-1.png}     \caption{A first figure in Problem 1.}     \label{fig:mwe_1-1} \end{figure} \begin{figure}[ht]     \centering     \includegraphics[width=0.4\textwidth]{mwe_1-2.png}     \caption{A second figure in Problem 1.}     \label{fig:mwe_1-2} \end{figure} \end{problem} \newproblem \begin{problem} Curabitur cursus vitae diam sit amet imperdiet. Pellentesque eleifend libero ut dui venenatis faucibus. Proin iaculis ligula nisi, vitae rhoncus enim ultrices quis. Donec quis lacus sit amet lacus posuere feugiat. Vestibulum in condimentum nulla. Sed ornare velit sit amet eros dignissim egestas. Orci varius natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. In luctus condimentum elementum. Duis quis volutpat lacus. Fusce finibus enim eget turpis hendrerit, sed lacinia lectus efficitur. Maecenas vel libero metus. Cras quis placerat lacus. Donec ac sapien eu tellus elementum egestas non dictum diam. Donec a posuere neque, non euismod dolor. See Figure \ref{fig:mwe_2-1}. \begin{figure}[ht]     \centering     \includegraphics[width=0.4\textwidth]{mwe_2-1.png}     \caption{A first figure in Problem 2.}     \label{fig:mwe_2-1} \end{figure} \end{problem} \end{document}  You may wish to copy the MWE to your machine and typeset it there to better understand my question. The idea is that the figure and table counters would reset after every problem. The downside was that I would have to type in \newproblem or \newproblem* after every single problem, which obviously is very inelegant. This was originally a stopgap method to be used until I was better acquainted with the float system and hyperref. The method worked for a while. However, very recently I tried to click on the hyperlink for Figure 2.1 in the MWE above, and it redirected me to Figure 1.1 instead. It appears that hyperref could only read the figure counter and not the problem counter, so it linked the references to Figure 1.1 and Figure 2.1 in the copy all to Figure 1.1, as they shared the same figure counter. What I am looking for is a method to remedy this issue, i.e. design a method to allow figures and tables to be numbered as described above, while still linking references to figures with the same figure counter but different problem counters to the correct figures. Any advice to avoid having to manually type \newproblem after every problem would be welcome as well.

Some document elements (e.g., figures in the book class) are numbered per chapter (figure 1.1, 1.2, 2.1, ...). How can I achieve continuous numbering (figure 1, 2, 3, ...)?  And vice versa: Some document elements (e.g., figures in the article class) are numbered continuously. How can I achieve per-section numbering?  \documentclass{book}% for "vice versa" variant, replace `book` with `article`  \begin{document}  \chapter{foo}% for "vice versa" variant, replace `\chapter` with `\section`  \begin{figure} \centering \rule{1cm}{1cm}% placeholder for graphic \caption{A figure} \end{figure}  \end{document}   Bonus question: Is it possible to adjust the numbering of the sectioning headings themselves? Can I, e.g., switch from per-chapter to continuous numbering of sections in the book class?


I upgraded my Dell XPS 13 Developer Edition laptop from 12.04 to 13.04 and now it seems the Mini Display Port isn't working at all. I've tried using an Apple-branded Mini DP to VGA adaptor and a generic Mini DP to HDMI adaptor and neither is detected. Here's my terminal output:  hellocatfood@computerfood:~$ xrandr -q Screen 0: minimum 320 x 200, current 1920 x 1080, maximum 32767 x 32767 eDP1 connected 1920x1080+0+0 (normal left inverted right x axis y axis) 294mm x 165mm    1920x1080      60.0*+   59.9     40.0      1680x1050      60.0     59.9      1600x1024      60.2      1400x1050      60.0      1280x1024      60.0      1440x900       59.9      1280x960       60.0      1360x768       59.8     60.0      1152x864       60.0      1024x768       60.0      800x600        60.3     56.2      640x480        59.9   VGA1 disconnected (normal left inverted right x axis y axis) HDMI1 disconnected (normal left inverted right x axis y axis) DP1 disconnected (normal left inverted right x axis y axis)   Any suggestions for making this work are very welcome!

My notebook is connected to a HDTV through a KVM Switch (one other notebook also connected to the same HDTV). The problem seems to be that Ubuntu doesn't recognize the HDTV to be turned on and therefore doesn't enable the VGA output. As far as I understand it has something to do with EDID information not being send trough the KVM Switch.  xrandr won't enable the VGA output through xrandr --output VGA1 --auto, it just keeps showing as disconnected.  Can I somehow force the VGA port to send a signal?  My Graphics Controller:  Intel Corporation Mobile 915GM/GMS/910GML Express Graphics Controller (rev 03)


I have one .txt file which has more than 1 million record inside. (rownum from 1 to 1 million) I need to divide this file into two 500k files in linux. (file1 = rownum from 1 to 500k and file2 = rownum from 500k to 1 million).    How can I do it?

I have a big file and need to split into two files. Suppose in the first file the 1000 lines should be selected and put into another file and delete those lines in the first file.  I tried using split but it is creating multiple chunks.


Let $n \geq 2$. I need to show that $\sqrt{2\sqrt{3\sqrt{4...\sqrt{n}}}} < 3$ for all $n \in \mathbb{N}$. I tried using logarithms and got arithmetico-geometric like series, except for the $\log$ operator. Can't think of a useful inductive argument here.

Problem: prove $\sqrt{2\sqrt{3\sqrt{\cdots\sqrt{n}}}}<3$ by induction. I tried some, but stopped in $\sqrt[2^n]{n+1}$. Also tried with $2\sqrt{3\cdots}<3^2$ and so on.


I was following     It worked when I tried it on a VM (running ubuntu). But while executing on my actual machine, I noticed, my /bin/ folder is missing.  root@akki-X555LAB:/usr/local/ssl# ls certs  misc  openssl.cnf  openssl.cnf.dist  private     The command I was trying to execute was:  ln -s /usr/local/ssl/bin/openssl /usr/bin/openssl   I was simply following the commands in that link and don't understand what went wrong! For reference:  root@akki-X555LAB:/usr/local/ssl# openssl version openssl: error while loading shared libraries: libssl.so.1.1: cannot open shared object file: No such file or directory

I try to compile the latest version but I get this error message.   $ make OPENSSL=/usr/local/ssl Makefile:82: ../aolserver/include/Makefile.module: No such file or directory make: *** No rule to make target '../aolserver/include/Makefile.module'.  Stop.   What should I do about it?


Prove by induction that $\sum_{k=1}^{n}$ $k \binom{n}{k}$ $= n\cdot 2^{n-1}$ for each natural number $n$.

Proof that $\suṃ̣_{k=1}^{n}k {n \choose k}$ for $n \in \mathbb N$ is equal to $n2^{n-1}$.  As a hint I got that $k {n \choose k} = n {n-1\choose k-1} $.  I tried solving this by induction but, in the inductive step I'm not arriving to the correct result.


I just started learning Blender and I noticed that there are two engines "Blender render" and "cycles render". I'd like to know what is the difference between them in term of Tools, interface (not really rendering time)? I wonder can i first learn Blender Rendering and then switch to Cycles render and use it as easy as trained Blender render? If they do differ so much, please list main advantages and disadvantages. Thanks.

How does Cycles work and how is it different from Blender Internal?  Which is better?


i am trying to do the following: var cars = []; var newCar = "toyota"; cars.push({ newCar: { year: 2000, } })  it saves newCar as "newCar", not as "toyota". How can I do it?

I'm pulling items out of the DOM with jQuery and want to set a property on an object using the id of the DOM element.   Example  const obj = {}  jQuery(itemsFromDom).each(function() {   const element = jQuery(this)   const name = element.attr('id')   const value = element.attr('value')    // Here is the problem   obj.name = value })   If itemsFromDom includes an element with an id of "myId", I want obj to have a property named "myId". The above gives me name.  How do I name a property of an object using a variable using JavaScript?


In order of importance:   Add a reason field for rollback Notify the author of the edit that's being rolled back of the rollback and the reason Notify the approvers of the edit too (if they exist due to editor's low reputation) of the rollback and the reason   A few times after I've received edit notifications for answer of mine, which other users have (incorrectly!) approved, I have then rolled back the edit, because the edit was in fact wrong. I really wanted to add a message for why the edit was rolled back.  Why isn't there a field to add a (optional) message for why the edit is being rolled back, similar to the "Edit summary" field for an edit?  In addition to the message field, I really wanted the other user to be notified about the roll back, and notify tell the users who approved the edit (if any), so they are more careful in the future.

I just had an occasion where someone reformatted the code in my question, not because it was ill-formatted, but to match his preferred style. I would have liked to be able to type a reason for rolling back the edits when I did so - could the ability to do that be added?


Is there a key combination for bash to auto compete a command from the history? In ipython and matlab for example this is achieved by pressing up arrow after typing a few characters.

So, I've looked at history and at Ctrl+R, but they are not what I thought I knew. Is there a way that I can type in the beginning of a command, and cycle through the matches in my history with some bash shortcut?  # mysq(some shortcut key)   Gives me:  # mysqldump  --add-drop-table -e -q -n -C -u  (some shortcut key) #  mysql -u ben.dauphinee -p


Just purchased the MX Anywhere 3. Works perfectly on the Mac, but I cannot re-assign buttons on my working laptop that has Ubuntu 18.04.5 LTS. I would like to reassign "copy/paste" actions as my current "back/forward" buttons. Any idea how to solve this? Thanks

I have a mouse with lots of buttons, but it's not a mainstream make like Logitech. For Windows, I have a driver that lets me assign actions like close-window (Ctrl+W) or next-tab (Ctrl+Tab), but I don't have a Linux driver. Since Linux is so flexible, I thought perhaps there is a general way to do this, regardless of brand?  Update: Based on input from Cyrex, I installed and ran sudo apt-get install btnx which found several but not all mouse buttons. Found: left, right, wheel, wheelclick, thumb fwd, thumb back. Not found: wheel left, wheel right, thumb middle button. Vendor ID is 0x04d9, Model ID is 0xa015.  Update 2: In System>Prefs>Mouse there's a lightbulb icon for testing double-click speed. Every working button can turn the bulb on&off, but the missing buttons can't. It would seem that Ubuntu isn't aware of these buttons and thus doesn't register their clicks. I guess I need to hunt for a driver, though a mainstream mouse is probably the easier way.


I know about , but the accepted answer (use offline installer) keeps the Java auto-update (jucheck.exe) from downloading, and it makes it harder to update about a dozen PC's running various versions and editions of Windows.  So: is there a way to prevent the Ask Toolbar and Ask Toolbar Updater from installing when the Java Autoupdate (jucheck.exe) runs?

As many are painfully aware of, Oracle continues to not only bundle the Java installation with the useless Internet browser toolbar from Ask.com, but also enable its installation by default. In addition to the toolbar, Ask also replaces your favourite search engine in your browser with Ask.  Furthermore, the Java installation goes as far as to actually recommend installing this useless junk, meaning that any non IT-savvy person is more than likely to leave it checked and install it (after all, it was enabled by default and the friendly Java installer did recommend it, right?).  To add insult to injury, even if you remove the Ask Toolbar, you can be sure to see it again soon, when the next Java update hits you (which seem to happen quite often lately, due to loads of security fixes for Java, but that's another story).  I'll duly remove the check-mark to install Ask Toolbar, whenever I update Java, but when supporting my family and friends, it's obvious they don't.  How can I prevent the pesky Ask.com Toolbar from being installed in the first place?


I've looked at the  for the C++11 regex library and can't seem to find anything on the runtime of its regex_search() method. Suppose I have a string of length n and a pattern of length m, how can I analyze the complexity of this search?  Below is an example of using this method to find and print occurrences where the string is of an alphabetical letter and a digit:  How do I find the runtime of this?  string s = "h2ello1"; regex re("[a-z]{1}[0-9]{1}"); smatch m;  while(regex_search(s,m,re)){     cout << m[0] << endl;     m.suffix().str(); };    EDIT: A lot of the previous questions mention "to build a Deterministic Finite Automaton" which can lead to the runtime but I'm only using a C++11 library. Is it the same implementation? I know it's definitely not linear time because it is pretty slow.

I didn't get the answer to this anywhere. What is the runtime complexity of a Regex match and substitution?  Edit: I work in python. But would like to know in general about most popular languages/tools (java, perl, sed).


Is it grammatically correct to say "everything is good"? And why is "everything is well" correct? Isn't "well" an adverb?  Edit: I'm looking for an answer for this phrase specifically.

I know good normally is an adjective ("[object] is good"), and well is normally an adverb ("[activity] is performed well"). But quite a few times I've seen good used in place of well. For example, you can be feeling good.  When is good applicable as adverb? Is the vice-versa situation possible?


Whenever we hear a crew member playing music aboard one of the Starfleet ships in the series (Enterprise or Voyager) it's usually something classical, jazz, or something else easy listening.  Does rock music or metal not exist anymore in the 24th century? Would this music be considered too 'violent' for human culture of the future? It would likely be something better suited to a Klingon's musical tastes.  We never hear a crew member mention "I'm listening to a band from the 20th century who called themselves The Rolling Stones" for example.

Every time we see a recital given aboard any ship or star base, it's almost always a 'classical music' recital or performance, never a rock concert. The only exceptions to this musical bias are Riker's penchant for Jazz and Zefram Cochrane playing 'Magic Carpet Ride' during the 'First Contact' launch.


I'm learning modern C++ and sometimes I see values passed by reference written slightly differently with a space.   int &i   Is there a difference?  int& x     #include <iostream> using namespace std;  void swapnum(int &i, int &j) {   int temp = i;   i = j;   j = temp; }  void f(const int& x) {   int& y = const_cast<int&>(x);   ++y; }

I've recently decided that I just have to finally learn C/C++, and there is one thing I do not really understand about pointers or more precisely, their definition.  How about these examples:   int* test; int *test; int * test; int* test,test2; int *test,test2; int * test,test2;   Now, to my understanding, the first three cases are all doing the same: Test is not an int, but a pointer to one.  The second set of examples is a bit more tricky. In case 4, both test and test2 will be pointers to an int, whereas in case 5, only test is a pointer, whereas test2 is a "real" int. What about case 6? Same as case 5?


I often find that I see something and I flag it up, but then the post is edited and I want to undo my flag.  So I think that a feature which would allow for you, at least within the first 5-10 minutes of taking the action, to reverse it.

I'm wondering (since it just happened to me), is it possible to "cancel" ("undo", "delete", "retract", whatever) a flag I just raised if I misclicked it, so the mods won't waste time?  I looked everywhere, but I can't find such a feature.


How can I show that  $\{\emptyset,\{\emptyset\},\{\{\emptyset\}\},\{\{\{\emptyset\}\}\},...\}$ is a set using the ZFC axioms only?  I know that $S(\emptyset)=\{\emptyset\}$. How could I prove the above strictly?

Define M:  $$ \emptyset \in M \wedge \forall x\in M \rightarrow \{x\}\in M $$ How to construct this set in ZFC system?  I know the axiom schema of replacement and the definition of recursion, but first I need a function to produce this set. A function is a map of pairs, so M must be the subset of the function's codomain, which means I still need M before I use the function...