How can I display result Stream<int[]> allResults = list.stream();  I try:  allResluts.forEach(System.out::println);

In Java, arrays don't override toString(), so if you try to print one directly, you get the className + '@' + the hex of the  of the array, as defined by Object.toString():  int[] intArray = new int[] {1, 2, 3, 4, 5}; System.out.println(intArray);     // prints something like '[I@3343c8b3'   But usually, we'd actually want something more like [1, 2, 3, 4, 5]. What's the simplest way of doing that? Here are some example inputs and outputs:  // Array of primitives: int[] intArray = new int[] {1, 2, 3, 4, 5}; //output: [1, 2, 3, 4, 5]  // Array of object references: String[] strArray = new String[] {"John", "Mary", "Bob"}; //output: [John, Mary, Bob]


Why does the number of results in Google can sometimes drastically depend on the browser? (e.g., 61,800,000 results vs 78 results) E.g., with the query "By the end of today", on Chrome:  on Firefox:  Both screenshots are from the 1st page.

That's kind of a recursive Google Search that should be self-explanatory. It did take me some time to tweak the sentence and trying to find a number which would correspond precisely, the reason why I changed it to "hundreds" instead! :P  If you have used Google long enough you certainly have stumbled on situations similar to this, many times. Whenever it shows less than 10 pages it's quite easy to see it. The point is: the number of results on any page except the last one seems like a terrible estimate.  What's even weirder,  the estimate suddenly becomes much better and almost exactly the same on all pages than it is on the last page - the only page that's always correct.  So, anyone knows why?


whenever i press f12 in blender 2.8, it doesn't start to render. In the other hand, it only shows this   if you can help me , please leave your suggestion in the comment. thank you.

A scene I made is not rendering, at all. This grey screen stays the same and nothing changes.  Here are my settings:  [


I try to save some data I get into a form in the database but I don't know how to do it.  Currently, here is what I have in the database (I try to add articles). As you can see I already have 2 of them but I set them using directly the CMS. Now I would like to be able to modify these data (for exemple the title of an article) and even add new full articles if possible.     To get the articles this is what I am doing (it works).      $query = \Drupal::entityQuery('node');     $query->condition('type', 'Article');     $items_ids = $query->execute();     $items = Node::loadMultiple($items_ids);   How do I set the title for the article 2 to title 2 changed?

I can create a node using the following code:  $node = \Drupal::entityTypeManager()->getStorage('node')->create($array);   But if I have the node ID, how can I edit a node?


im working on a PDE question. which states :  find Fourier transform on this given function the function is: $$f(x)=e^{-\alpha x^2} , \alpha > 0$$ we know that for Fourier transform : $$F(w)=\frac{1}{\sqrt{2\pi}}\int_{-\infty}^{\infty} f(x) e^{-iwx} dx$$ so $$F(w)=\frac{1}{\sqrt{2\pi}}\int_{-\infty}^{\infty} e^{-\alpha x^2} e^{-iwx} dx$$ how should I solve this ? I tried to simplify it but it just got more complicated.

I would like to work out the Fourier transform of the Gaussian function   $$f(x) = \exp \left(-n^2(x-m)^2 \right)$$  It seems likely that I will need to use differentiation and the shift rule at some point, but I can't seem to get the calculation to work. Does anyone have any advice?  By the way, I am using   $$\mbox{FT}(f)(k)=\int_{-\infty}^\infty f(x)e^{-ikx}\,\mathrm d x$$  as my definition of a Fourier transform. Many thanks.


I remember reading a story in which unwanted infants were sold as food in open markets, although I don't think that was the main theme of the story.  It was published in a monthly science fiction magazine (i.e. Analog, Fantasy & Science Fiction, Astounding Stories, etc), so it could have been a short story, novella, or serial.  It was in English.  I think it was in the 1970's, but I've been reading science fiction since 1954 and it could have been anytime since then.    I thnk they were sold alive. I don't know why they were sold.  They were infants, i.e. under a year old.  The planet was not Earth.  The inhabitants were intelligent, but I don't recall whether they were native or colonists.  I remember a scene in which a woman was grocery shopping and checked an infant's leg for tenderness by squeezing it.

Trying to remember the name/author of a book:   Long book. Many many separate small chapters. Scifi about humans, on non-Earth planet. They have poisonous native life, and can only eat a few brought from Earth plants. Because of that, they practice cannibalism, to no waste human body proteins. The story opened with consuming a body of someone who recently died. It had a pretty complex plot, with politics, war, technology, social structures, etc.  Social/sexual customs were kind of weird even leaving aside rituals around cannibalism. But it was NOT Heinlein, I'm sure of that :)   I don't know the year it was published, but it was pretty old, I took it around 1993-95 from a library and the physical book looked well-read by that time.


Below is my regular expression that matches url in a text which contains regular text, url and email ids. Problem here is,it also picks up the domain part from email ids.   /(?:(?=[\s`!()\[\]{};:'".,<>?"'])|\b)((?:[a-z][\w-]+:(?:\/{1,3}|[a-z0-9%])|www\d{0,3}[.]|[a-z0-9\-]+[.][a-z]{1,4}\/|[a-z0-9\-]+[.](?:[a-zA-Z]{2,4}))(?:[^\s()<>]+|\(([^\s()<>]+|(\([^\s()<>]+\)))*\))*(?:\(([^\s()<>]+|(\([^\s()<>]+\)))*\)|[^\s`!()\[\]{};:'".,<>?"']|\b))/   Here is the text  Is there a way to filter out the entire email id  My text     Neque porro quisquam est qui dolorem ipsum quia dolor sit amet,   consectetur, adipisci vel  eque porro quisquam est qui dolorem ipsum quia dolor sit amet xyz@abc.com   Matches     , abc.com   It should not match abc.com in xyz@abc.com

How can I check if a given string is a valid URL address?  My knowledge of regular expressions is basic and doesn't allow me to choose from the hundreds of regular expressions I've already seen on the web.


I python script called scrape.py. As the name suggests it is a web crawler and I want it to run continuously on my Linux machine even after I log out and end the ssh session. I read a lot around here and there were many suggestions of using nohup python scrape.py &. This worked well but the script execution stopped as soon as I logged out. I also explored the supervisor application but I don't have root permissions so it fails too. Can you suggest me a way to solve this problem? Thank you.

Let's say I launch a bunch of processes from a ssh session. Is it possible to terminate the ssh session while keeping those processes running on the remote machine?


Here is the example that came up today: My mother went to the park to _______ birds.  Would you use look at or watch, and why?

When should I use "look", "see", and "watch"?     I'm watching "Star Trek".   Have you seen "Star Trek"?   Are the examples above correct?


I got an array  string [] strings = new string[] {"1", "2", "2", "2", "1"};  You can see the value of the array is just 1 and 2, just 2 values, you could say, and I want to get those value out...What I did is here, just a start:  string[] strings = new[] { "1", "2", "2", "2", "1"}; int[] ints = strings.Select(x => int.Parse(x)).ToArray();   I don't what is next...Anyone helps?

I have been working with a string[] array in C# that gets returned from a function call. I could possibly cast to a Generic collection, but I was wondering if there was a better way to do it, possibly by using a temp array.  What is the best way to remove duplicates from a C# array?


While the idea of extra spatial dimensions has been around for quite a while now, is there a possibility or any theory which proposes extra time dimensions?  If so, what could be theoretical implications of multidimensional time on existing theories like relativity or QM?  Would they work just fine?

It’s easy, relatively speaking, to develop an intuition for higher spatial dimensions, usually by induction on familiar lower-dimensional spaces. But I’m having difficulty envisioning a universe with multiple dimensions of time. Even if such a thing may not be real or possible, it seems like a good intellectual exercise. Can anyone offer an illustrative example?


1) In my previous role as a cook at Company A ....  or  2) At my previous role as a cook in Company A ....  Which is more appropriate to write?

I am not sure about what is right:     I can start my career at an international company.   or     I can start my career in an international company.   For me at sounds appropriate?


I will be traveling from Oslo to Dubai through Doha with Qatar airways. When I arrive in Dubai I have 80 minutes to my next connecting flight (which is a separate ticket booked with the same airline) back to Doha again. By doing this you can save a lot money! But I`m wondering how the baggage is handled in Dubai before my flight back to Doha again?

I have two different bookings on British Airways and Emirates.  Booking 1 (British Airways): Washington (IAD) -> London (LHR) -> Dubai  Booking 2 (Emirates): Dubai -> Hyderabad  I have a 5 hour stop in Dubai but do not have a visa to leave the airport. British Airways says they won't through-check my bags. Emirates says it won't be a problem since Emirates and BA are partner airlines.   Not sure what I should do at this point. My flight is tomorrow so its too late to apply for a visa. I have actually done with before without a problem on the same two airlines. The only difference was that it was on a single ticket booked through a travel website.


L has just thought of a cunning plan to prevent himself being killed by a Death note:      He straps a device to his heart that directly links to an equivalent device strapped to Watari's (his butler) heart. If either heart stops beating (or the device is removed), then the other self-detonates and kills the other person. Which thus renders the Death note essentially useless against either of them, given the following rule:   Even though only one name is written in the Death Note, if it influences and causes other humans that are not written in it to die, the victim’s cause of death will be a heart attack ~ Rule XXVI - II linked   Is this possible, or would L just die from a heart attack anyway?

There are Mr. A and Mr. B. They are conjoined twins who each has their own set of organs except for the heart. I write the name of Mr. A while imagining his face, with the cause of death being falling from the top of Tokyo Tower head first. Let's say the difference in height between the two is less than 1 cm. Will Mr. B also die?  According to , item 2:     Even though only one name is written in the Death Note, if it influences and causes other humans that are not written in it to die, the victim's cause of death will be a heart attack.   However, a heart attack will also kill Mr. B.  Additionally, , item 2 stated:     Whether the cause of the individual's death is either a suicide or accident, if the death leads to the death of more than the intended, the person will simply die of a heart attack. This is to ensure that other lives are not influenced.     This question is a bit different than . In the proposed question, the death of the pilot or the surgeon doesn't necessarily means that the people in the plane or the one in the surgery will 100% die. There is a delay before they actually die. Surgery is rarely done by only one doctor. It usually is done by a team of doctors, so the other doctors can still save the patient. Flying a plane is also the same. There is also the co-pilot. In the case of my question, killing Mr. A is the same as killing Mr. B since they share the same heart with no delay whatsoever to save Mr. B.


I've got one installation of SQL Server Enterprise and a couple of satellite installations of SQL Server Express. I can't justify additional installations of SQL Server itself for these satellites.  The documentation for SQL Server Express clearly states that it's limited to .  What I can't seem to ascertain is whether this restriction for SQL Server Express really is per instance or per server. Some documentation uses the word "instance". Other documentation does not.  Instances don't seem to be much of an overhead (these days much of the SQL Server application is a shared installation, contrary to ). If this is an effective get-by to run several small-ish databases on the same server then that would be very convenient.  Can someone help clarify whether the limitation is per instance or per server, please?

This is a  about Licensing.    Questions on licensing are off-topic on Server Fault.  If your question has been closed as a duplicate of this question, then this is because we want to help you understand why licence questions are off topic rather than just telling you "it just is". In all likelihood, this question will not address your question directly, it was not meant to.    I have a question regarding software licensing. Can the Server Fault community please help with the following:   How many licenses do I need? Is this licensing configuration valid? What CALs do I need to be properly licensed? Can I run this product in a virtual environment? Can I downgrade this product to an earlier version? Am I entitled to feature X with license Y?


I'm having trouble starting with the base case even. So far I've set  $$ f_n(x)=1 + x +\frac{ x^2}{2!} + ··· + \frac{x^n}{n!}. $$  For $n = 0$, $e^x>f_0(x)$, but I'm not sure that's the correct base case since usually $n=1$ is used.   From there, I'm having dificulty establishing $e^x>f_{k+1}(x)$.  I can use derivation, but cannot use integration of any kind. I must use indiction. I do not have a formal definition of $e^x$, and my textbook is not useful or good.  EDIT: I cannot use the power series of $e^x,$ my apologies for taking the question incorrectly!

Show that if $n \geq 0$ and $x>0$, then   $$ e^x > 1 + x + \frac{x^2}{2!} + \dots + \frac{x^n}{n!}.$$  Not sure where to get started with this induction proof.


At the site  I just searched for a keyword, and the page sent me to a Human verification page with a CAPTCHA image. Unfortunately, I couldn't determine the correct words. Here are some samples:   Because the captcha changes for every failed attempt, I do not have a second chance with one. Now I am struck here at this captcha:     Would anyone care to tell me what these letters are so I can complete my request?  When I do a search the SE server displays a verification page. But I can solve those because they are simple like this one:    or some simple images with text. But the first three CAPTCHAs in this question are much more difficult (at least for me).   Why do some SE sites use much more difficult CAPTCHAs compared to others? (And of course very often while searching)

I seem to be unable to pass the Turing test:        I get this when I want to do a search on Ask Ubuntu.  Can you guess what this says? Neither can I. It's very, very difficult to read. In the last week, I tried 30+ times1. I failed all of them. I also tried the audio a few times, but that's perhaps even worse ... I  can sign in, and that "solves" it insofar that I can do a search, but I would just like to do a quick search without logging in on 100+ sites...  I realize the need for these sorts of system, and I also know that StackExchange doesn't develop this system, but can they be made more usable, somehow?  Related:     1: Yes, really. I've been searching quite a few SE sites to see what sort of questions are being asked and how meta discussions are being held.


Been asked to write "x is good for your Customer's vehicle interior". I feel this should be "Customers' vehicle interiors" but am spinning in circles on it. Can you help break the stalemate in my head?!

In a situation where say a group (or at least a plurality) of men is being addressed — for example on a sign passed by many married men — which is correct?  "Remind your wife."  or  "Remind your wives."


I found out that if someone was able to hack any FTP account on my server and upload Adminer they could alter the database. I tried Google'ing a way to block or prevent Adminer from working, but got no where. Anyone have any ideas?

This is a  about Server Security - Responding to Breach Events (Hacking)   See Also:                  Canonical Version I suspect that one or more of my servers is compromised by a hacker, virus, or other mechanism:   What are my first steps? When I arrive on site should I disconnect the server, preserve "evidence", are there other initial considerations? How do I go about getting services back online? How do I prevent the same thing from happening immediately again? Are there best practices or methodologies for learning from this incident? If I wanted to put a Incident Response Plan together, where would I start? Should this be part of my Disaster Recovery or Business Continuity Planning?   Original Version       2011.01.02 - I'm on my way into work at 9.30 p.m. on a Sunday because our server has been compromised somehow and was resulting in a    attack on our provider. The servers access to the Internet   has been shut down which means over 5-600 of our clients sites are now   down. Now this could be an FTP hack, or some weakness in code   somewhere. I'm not sure till I get there.      How can I track this down quickly? We're in for a whole lot of   litigation if I don't get the server back up ASAP. Any help is   appreciated. We are running Open SUSE 11.0.            2011.01.03 - Thanks to everyone for your help. Luckily I WASN'T the only person responsible for this server, just the nearest. We managed   to resolve this problem, although it may not apply to many others in a   different situation. I'll detail what we did.      We unplugged the server from the net. It was performing (attempting to   perform) a Denial Of Service attack on another server in Indonesia,   and the guilty party was also based there.      We firstly tried to identify where on the server this was coming from,   considering we have over 500 sites on the server, we expected to be   moonlighting for some time. However, with SSH access still, we ran a   command to find all files edited or created in the time the attacks   started. Luckily, the offending file was created over the winter   holidays which meant that not many other files were created on the   server at that time.      We were then able to identify the offending file which was inside the   uploaded images folder within a  website.      After a short cigarette break we concluded that, due to the files   location, it must have been uploaded via a file upload facility that   was inadequetly secured. After some googling, we found that there was   a security vulnerability that allowed files to be uploaded, within the   ZenCart admin panel, for a picture for a record company. (The section   that it never really even used), posting this form just uploaded any   file, it did not check the extension of the file, and didn't even   check to see if the user was logged in.      This meant that any files could be uploaded, including a PHP file for   the attack. We secured the vulnerability with ZenCart on the infected   site, and removed the offending files.      The job was done, and I was home for 2 a.m.            The Moral   - Always apply security patches for ZenCart, or any other CMS system for that matter. As when security updates are released, the whole   world is made aware of the vulnerability.   - Always do backups, and backup your backups.   - Employ or arrange for someone that will be there in times like these. To prevent anyone from relying on a panicy post on Server   Fault.


Let X be the set of all real numbers different from zero and one. Let G be the set consisting of the following transformations of X : ,   a1x=    x a2x=1/x , a3x=1-x , a4x= x/(x — 1), a5x= (x — 1)/,a6x = 1/(1 — .x)  Prove that G is a group of transformations, and construct the multi¬plication table for G

I have trouble understanding the following task:     Show that the set $X = \{f_1,\ldots ,f_6\}$ of functions $f_i : \Bbb Q\setminus \{0,1\} \to \Bbb Q\setminus \{0,1\}$ with   $x ↦ f_1(x) = x$,$x ↦ f_2(x) = 1/x$,$ x ↦ f_3(x) = 1-x,$ $x ↦ f_4(x) = 1/(1-x)$,$ x ↦ f_5(x) = (x-1)/x$, $x ↦ f_6(x) = x/(x-1)$   and the composition as the operation is a group. Is this group commutative?    I'm a little confused as I don't know what to do with all these functions. I can't apply the definitions of a group on this because of that. If the group is $(X,∘)$ how do I show that this is associative don't I need the information on how the single functions are connected or am I missing something?


I know that $100!$ is $100\times99\times98\times...2\times1$ but I don't get how to get all the factors of three from this. Help!

One common math puzzle I've seen around asks for how many zeros are in the product of "100!"  Usually, the solution everyone gives goes something like try to match pairs of 5s and 2s that factor out of the numbers, which ends up being 24 zeroes (you can factor a 5 out of 20 of the numbers, and factor 2 5s out of 4 of the numbers; you can factor more than  24 2s out).   This however as far as I know gives the number of trailing zeroes at the end of the number, but does not account for the zeroes that are within the number. My question is, is this answer correct anyways? Can there be zeroes that aren't trailing that are inside? Why or why not and if there can be can we somehow figure out how many are within the product?   Thanks


ok so what I'm trying to do is to get the element's with the class name 'no-js' and replace it with 'js', so I have NO idea how to do this, I tried google around But couldn't find anything, so does anyone now how to do this?  what I'm trying to make Is this menu that when you click on a Plus button it has this drop down menu, but if javascript is disabled I want it to show on hover with css ( i've already done that )  i've put My code on JsFiddle, heres the link:   thanks.

How can I change the class of an HTML element in response to an onclick or any other events using JavaScript?


I have written a simple code to read a 2d integer array of size n1 and n2 and print the middle element in java. import java.io.*; import java.lang.*; import java.util.*; public class Main {     public static void main(String args[])throws IOException {         BufferedReader br=new BufferedReader(new InputStreamReader(System.in));         int n1=Integer.parseInt(br.readLine());         int n2=Integer.parseInt(br.readLine());         int[][] arr=new int[n1][n2];         System.out.println("n1"+n1+"n2="+n2);         String[] sarr=new String[n2];         for(int i=0;i<n1;i++) {             sarr = br.readLine().split(" ");//line 13             for (int j = 0; j < n2; j++)                 arr[i][j] = Integer.parseInt(sarr[j]);         }         System.out.println(arr[n1/2][n2/2]);     } }  I was getting the below error in an online compiler but when executed in intellijIDEA there was no error. Exception in thread "main" java.lang.NullPointerException     at Main.main(Main.java:13)

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 returned from Sweden 11/20/18 after a 90 day visit there.  When can I return to Sweden for 30 days?

I have searched the web a lot and could not find an answer that fits my situation. Here are two links that are quite contradictory:       My situation:  I've visited Portugal in December 2012 for 29 days on a Schengen visa valid from December 1st, 2012 to February 1st, 2013 for research purposes (I am a Ph.D. student). I want to visit Sweden from February 10th, 2013 to May 10th, 2013 (89 days). I have applied for a Schengen visa again (for research). How will the 90/180 rule work in my situation?


I had paid my bill. I paid my bill.   I just want to make sure that the first sentence is correct. I understand that the second sentence is called simple past. If I use had as in the first sentence, is it still called past perfect tense? Or that is wrong English since there is no other action mentioned (e.g.: I had paid my bill before going home).  And with regards to the second sentence, is it correct to use simple past form like that even if no specific time was mentioned?  Thanks!

I noticed that my American friends tend to use the past perfect form when they use the verb mention in its past form, almost despite of the context of the sentence. I hear them say  "you had mentioned" a lot more often even in situations where the use of simple past would have been perfectly fine. Have you noticed it too and is it one of those unwritten rules, or is there a more formal explanation to it?  It seems like there was more verbs like that, but I am having a hard time remembering it now. If I do, I will edit the post and likely change the title to accommodate other verbs.


The question is pretty simple: what's the minimum distance that can be travelled via a Stargate?  I know two stargates cannot operate in close proximity, such as on the same planet, as one Stargate will override the other, rendering it inoperable while the other is in use. But could you use a Stargate to create a wormhole between Mars and Earth (if there was one on Mars) for example?   My memory is a bit rusty on SGU, but it seemed the Destiny was pretty close to some of the planets they gated to from the Destiny after dropping out of FTL.

Related Questions:        We all know that gates within close proximity to one another are unable to dial one another (SG-1; Solitudes), and that only one may be active within a certain volume of space (since it gains priority over other gates)(SG-1; Watergate)(ATL; Enemy at the Gate).  So the question then begs itself:  Assuming that two stargates are of the same model (i.e. both are Milky Way, Pegasus, Destiny, etc.), and assuming typical usage (i.e. transport of matter and energy), what would be the minimum distance required for one to be able to dial, connect, and establish a wormhole with the other?     NOTE: This question considers typical usage only. As @Eureka had mentioned in the comments, when atypical usage is considered, the minimum distance is technically zero (since the same gate is connected to but at different times). (This begs another question, what happens if the gate is active during the time your connecting to it through a solar flare?)


I'm pretty sure I've visited Stack Overflow and Meta Stack Overflow every day before 4 PM PDT (midnight UTC) for the past 50 days. I can recall seeing it say (I believe) 35(?) consecutive days visited a few weeks back. Then, all of a sudden, the counter reset on both sites. That got me wondering:  Say you visit at 6:30 UTC, would not visiting until 6:35 UTC the next day reset the counter, or do you just need to visit once every UTC day?

When does a day start on the Stack Exchange network? Some badges (Enthusiast, , ) and voting limits are bound by and relate heavily to the concept of a day. Do days correspond to calendar days? What time zone is used?  Related


I've been looking at this question but I can't figure out any ways to approach it. This is from a first year undergraduate number theory class.

I've read about Fermat's little theorem and generally how congruence works. But I can't figure out how to work out these two:   $13^{100} \bmod 7$ $7^{100} \bmod 13$   I've also heard of this formula:  $$a \equiv b\pmod n \Rightarrow a^k \equiv b^k \pmod n $$  But I don't see how exactly to use that here, because from $13^1 \bmod 7$ I get 6, and $13^2 \bmod 7$ is 1. I'm unclear as to which one to raise to the kth power here (I'm assuming k = 100?)  Any hints or pointers in the right direction would be great.


I moved to Canada and I want to change my country of region from USA to Canada, but when I try to change it ( by click on my account in the iTunes Store and going to my Account Page) it showed me this error: "You have a store credit balance; you must spend your balance before you can change stores"    I must mention I have redeem 100$ to my account but I don't have any intention to spent it now, what is my option?

I have a UK account but have relocated to Australia. I'm trying desperately to change my account details but the system won't let me as I have £10 credit on my UK account.  I don't mind losing the £10 I just want to change my details to my new Oz details.  Anyone know how? Also, is possible to credit the £10 to my Oz account as that would be fantastic.


What is the collective name for the digits before and after decimal point?

Sorry for asking such a basic question - but is there an actual term for the numbers that appear before and after the decimal point?  Example:  25.18  I know the 1 is in the tenths position, the 8 is in the hundredths position. are there singular terms which apply to all of the numbers that appear both before and after the decimal point?  I'm building a billing system, storing dollars and cents as integers (in separate columns), but for other currencies "dollars" and "cents" are not the correct terms = ).  Thanks!


First of all please accept my apologize for this basic question If It was. I have a real coding issue but just for the example I'd like to show you the code above. I'd like to understand why the first code is acting asboardI and board were pointing on the same reference and how to make the first code only modify boardI ?  board = []  board.append(["0"] * 10)  boardI = list(board) boardI[0].append("1") print board print boardI  >>[['0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '1']] >>[['0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '1']]     board = []  board.append(["0"] * 10)  boardI = list(board) boardI.append("1") print board print boardI  >>[['0', '0', '0', '0', '0', '0', '0', '0', '0', '0']] >>[['0', '0', '0', '0', '0', '0', '0', '0', '0', '0'], '1']   If I had declared boardI as boardI = board I'd have undertood but since boardI = list(board) it seems I missed something

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


I already installed ArcGIS 10.1 for Desktop.   The problem is when I install th Erdas Imagine 8.6 that specify above.   So, could you help me in order to run both software products in one PC.

ArcGIS Desktop 10 and ERDAS 8.7 were already installed in my computer. But I want to open both programs at the same time. If ArcGIS can open properly, ERDAS cann't open and vice verse, showed that following error (Fig.1).     IF I switch off ERDAS using License Manager Tools "LMTOOLS" (Fig.2), then ArcGIS can open properly, If I switch off ArcGIS using the same way above, ERDAS can open properly.     So what I want to ask are what is the reason for this problem and how to fix it?     I've changed "any" into 27002 and both "this_host" and "son" into "user_PC" which is my computer full name. This time Erdas can open correctly, but arcgis cannot. The following image is a problem with opeining ArcGIS Desktop.     Can you tell me what this means?    Thank you for your answer, U2ros. Here I'm adding some more photos of license files. According to your advice, when I opened both license files for arcgis and erdas, they look like this. First image is ArcGIS license file which is very similar with you described above except "son". I think I can change 27001 into 27005 etc.      Next image is license file of Erdas. This looks totally different from you described above. Here I'm fully confused which one is port number that I need to change to something like 27002. Can you give me further advice to for this.   .


A druid that is wild shaped reverts "when" they drop to 0 hit points.  Does that mean other effects that occur when a creature drops to 0 hit points also occur (though possibly in any order of the druid's choice)?  Specifically, if the druid were concentrating on a spell, would dropping to 0 hp - even momentarily - suffice to cause the druid to lose concentration by being incapacitated? I can't figure out what RAW or RAI is on this one - does anybody have any pointers (e.g. a rule or rule interaction I missed, or some sage advice)?

Consider the following situation (round numbers chosen for easier calculations):   Bob is a human druid. In caster form Bob has a +0 CON modifier and 100 current HP. Bob is concentrating on a spell. Bob is wild-shaped. His current beast form has a +5 CON modifier and a current HP of 30.   What concentration checks are required (including DC and modifier used on the roll) if:   Bob is dealt 30 damage Bob is dealt 60 damage   As far as I know concentration is not automatically broken in either situation because although  he is never unconscious.


I want to prove the following :  $$E\lvert X \rvert^{\alpha}=\int_{0}^{\infty} P\left\{\lvert X \rvert^{\alpha}>x\right\} dx=\alpha \int_{0}^{\infty} x^{\alpha-1} P\left\{\lvert X \rvert>x\right\} dx$$  The first equality is easy to prove. I'm having trouble with the second one. It appears to be some differentiation technique has to be used but I don't have a clue on how to proceed. Any help would be much appreciated.

If $X$ is a nonnegative random variable, we may compute the first moment by integrating the survival function:  $$ E(X) = \int_0^\infty S_X(x) \, dx $$  Is there a reasonable generalization of this for computing higher moments?


Given $a,b \geq 0$ and $2 \leq p <  \infty$ prove that $(a^p + b^p)^{1/p} \leq (a^2 + b^2)^{1/2}$. I tried using the convex function $f(x) = x^p$ and then prove $a^p + b^p \leq (a^2 + b^2)^{p/2}$ but can't seem to make any real progress. Can someone help me?

Q: For $p\in\mathbb{R}$ such that $2<p<\infty$, and $a,b>0$, prove the following  $$a^p+b^p<(a^2+b^2)^{p/2}$$  My attempt: I say it's equivalent to proving that $(a^p+b^p)^{1/p}<(a^2+b^2)^{1/2}$. Then I did binomial expansions on both sides of the inequality. Both the expansions have $a+b$ so I canceled them. For the rest of the terms, I thought I'd get geometric series on both sides and show that the series on the left is smaller than that of the right by using related sum formulas. But what I found were not quite geometric. For the left side  $$\frac{1}{p}a^{1-p}b^p+\frac{1-p}{2p^2}a^{1-2p}b^{2p}+\frac{(1-p)(1-2p)}{6p^3}a^{1-3p}b^{3p}+\ldots$$  While for the right  $$\frac{1}{2}a^{-1}b^2-\frac{1}{8}a^{-3}b^4+\frac{1}{16}a^{-5}b^6+\ldots$$  How to proceed to prove the inequality?


Finding the number of ideals in the quotient ring $\mathbb R[x]/\langle x^2-3x+2 \rangle$.  Attempt: $R[x]/\langle x^2-3x+2 \rangle = \{f(x)+\langle x^2-3x+2 \rangle~~|~~f(x) \in R[x]\}$.  Since $(x^2-3x+2)=(x-1)(x-2)$ is a reducible polynomials, the members of $R[x]/\langle x^2-3x+2 \rangle) = f(1)$ or $f(2) $ are essentially real constants.  out of which only $\{0\}$ is an ideal as $a \cdot 0 = 0 \in \{0\}~~\forall~~a \in \mathbb R$  Is my attempt correct?  Thank you for your help.

Find all ideals of $\mathbb R[x] / \langle x^2-3x+2\rangle$.   I know that $\langle f(x)\rangle \subseteq \langle x^2-3x+2\rangle$ iff $\langle f(x)\rangle$ divides $\langle x^2-3x+2\rangle$. But $\Bbb R[x] / \langle x^2-3x+2\rangle$ is all the combinations $(x^2-3x+2)q(x), q(x)\in \mathbb R[x]$, so isn't the ideals all of the polynomials in $\Bbb R[x]$? Probably not, but what am I missing here?


The icon in the middle it looks like dancing wobbling phone or something. Totally confused. Not using OnePlus. I'm using Cyanogenmod 13's HexoLibre theme.

does anybody know what's the meaning of that icon ?  I have a new oneplus one since several days and today this icon appeared in my status bar.


I did not see any advertisements (at least my Adblock counter didn't go up :P) and there also is nothing you can buy, so how does Stack Exchange finance all of these sites?

I once , but that was . Now, , and they have , but where's the business model? The  its own Q&A about its site (since it wasn't included in the ), and just about the only dig in there that halfway has merit is the business model dig:  We switched to a premium model to keep out of the Venture Capital business (been there, done that, got the t-shirt). Companies like StackExchange couldn't do it without the VC cookie jar. Where's the model? Huh, Spolsky? (I’m sorry. Did that slip out?)  It hurt, but I can't help but wonder if they're on to something.  How would Stack Overflow Internet Services pay back the VCs? Ad revenue alone?  There is only one 'paid' product, Stack Overflow careers, but it doesn't seem like that could sustain a business as large as Stack Overflow (Joel once mentioned on his blog that his jobs board brought in an extra million a year in revenue). So what does Stack Overflow do when the VC cash runs out? Is this a get-big-and-take-the-company-public maneuver? Is that the only viable business model for Stack Exchange? Edit: With the size of Stack Overflow's team, it isn't a stretch to say that payroll is at least $2 million  a year, probably as much as 4 when you think about benefits (average 120K for a developer in New York City; x2 for benefits/taxes/all-that-other-good-stuff). Office space can't be cheap, so how long does $6 million last before you need another VC infusion?


The context is a daily stand up meeting on a software project where developers tell the managers their status.  It is very easy for developers to bullshit, where they sound like they are busy, accomplishing something, doing something technical, or otherwise misdirecting.  These are empty words and can easily be called out.  What is a good business-ese word for this kind of bullshit?

For example, you're doing a research for a car to purchase. You get a list of cars with engine number, city where a car was assembled, and a color. What's missing is make, model and price.


I found the realm of User Experience one of the more wonderful sides of Software Engineering (and life).   Recently, I've installed Google Analytics on our website and I'm trying to study the data it provides and how I can use it to read what the users want. I've found it as the most fun and fulfilling task to do in all of my work life (which is not long, 1.5 years to date).  I've decided that I want my career path to veer towards this road.   Where and how should I start?    EDIT: I've changed the title to remove the focus on being a "UX Expert". My objective is to be set on a good path to start learning, and the previous title might have had different perceptions by people.

I've been a developer for over 6 years, mainly working in the web context, and generally distributed applications, services, and also front-facing apps. I got into programming originally through Interactive Design studies back in university, but then moved away from that as I'm most definitely not a graphic designer.  However, I really have a passion for visual arts, visual design, UI design, and user experience. When I say UI design, I mean more toward the Information Architecture side of things, as opposed to "graphic design".  With that in mind, How would a programmer make a career move into the User Experience area?  For example:   Would I have to go back to school (I really don't want to do this)? Do I just throw myself into the deep end and apply for jobs? Can I leverage the skills and experience I have as a software developer to help get work? What would a portfolio for a UI/User experience guy look like? What are employers looking for when they look for this kind of position? Would building some UI centric apps/wireframes in my own time help?


I want to get value of div attribute. Like I want to know whether the div is "display:block;" or "display:none" at the time of page load. If "display:block;" then it will be "display:block;" after the page load again if not then "display:none". Can anyone help me with jquery method or code?

Is it possible to toggle the visibility of an element, using the functions .hide(), .show() or .toggle()?  How would you test if an element is visible or hidden?


I'm trying to figure out how I can send arguments (which are contents in a file) on the command line as parameters to a cpp function. I am NOT trying to send it through stdin.  I have a function named foo.cpp:    $ cat foo.cpp   #include <iostream>   int main (int argc, char *argv[]) {       for (int i = 1; i < argc; i++)           std::cout << argv[i] << std::endl;       return 0;   }   $ g++ -o foo foo.cpp   $ ./foo hello world   hello   world   In the last command executed, I'm passing the arguments "hello world" into the program. However, what if I have "hello world" in a file? For example:   $ cat footest.args  $ hello world   How would I pass the contents of footest.args into ./foo as above? I've tried     ./foo | cat footest.args   But it doesn't seem to be working. What am I doing wrong?

I've got this situation:  ./ ./myscript.sh ./arguments.txt ./test.sh   Inside myscript.sh, I have to run the file test.sh, passing to it the arguments contained inside arguments.txt.  myscript.sh is:  arguments=$(cat arguments.txt) source test.sh $arguments   This works well if if arguments.txt contains at most one argument:  firstargument    The substitution is:  ++ source test.sh 'firstargument'   But the problem is with two or more arguments. It does this:  ++ source test.sh 'firstargument secondargument'   Also, I don't know in advance the number of arguments inside arguments.txt. There can be zero or more.


While learning about boolean algebra I came across this expression: $\{ 0,1 \}^n$. Given the context I understand that this is a set containing the values $0$ and $1$, but what the exponent here means is less clear, which leads me to my question: What does the exponent signify when the base is a set?

I'm reading .     The graph of $f: A \rightarrow B$ is the subset of $A × B$ consisting   of all ordered pairs $(a, b)$ with $f (a) = b$. If $A$ happens to be   $B^n$ for some $n ∈ N$, then we say that $f$ is a function on $B$ and   $n$ is the arity of $f$.   I don't understand the notation for the exponent of a set, I'm aware of what  is, it's the number of arguments or operands the function takes. I'm just not so sure if I can assume that a set with an exponent such as in $B^n$ means that a function has two operands.  I know the question may be too naive and perhapes the answer is the one I suggested and it's right in front of my face, I'm just searching for a confirmation or the negation of it. Thanks.


I have the following problem:  Let $ D=\lbrace x_{1} \dots x_{n}  \rbrace$ be a finite subset of $\mathbb{R}$. Proof that every function $f:D\rightarrow \mathbb{R}$ is continuous.  and following definition for continuous functions:  Let $f:D \rightarrow \mathbb{R}$ a function and let $a \in D$. Than $f$ is called continuous at $a$ if: Is $ $($ a_{n} $)$ $ a sequence in $D$, which converges to $a$, then the sequence $(f(a_{n})$ converges to $ f(a) $. The function $f$ is called continuous on $D$ if $f$ is continuous at each $a\in D.$  Just to get an idea of how to tackle this problem I took the function $\operatorname{sign}(x)$ ($1$ for $x>0$, $0$ for $x=0$ and $-1$ for $ x<0$) which is NOT continuous and a finite subset of $\mathbb{R}$, for example $D=\lbrace -2, -1, 0, 1, 2, 3 \rbrace$. According to the problem it should be possible to show that the function is continuous for the chosen $D$.  So I think what kind of sequence I could choose. Here the issues starts. Can I "define" a sequence in $D$ like $-2,-1,0,1,2$ which has the limit $3$? Or what would be a possible sequence? As far as I understood, I can only use elements from $D$ for the sequence members and the limit?!  Thanks

I struggling with R.K. Sundaram 1.7.43 exercise:   Let $S$ be a finite set. Show that any function $f: S \rightarrow \mathbb{R}^n$ is continuous on S. What if $S$ is countably infinite?  I saw that by  the definition of continuity is simple, but i'm havind douts with finite set definition.  Any thought would be appreciated.  tks


i need some ideas to solve $$\sum_{n=1}^\infty n\cdot\left(\frac12\right)^n$$ I prove that the series converges to using ratio method, but i dont know how to find the sum.

I would like to know: How come that  $$\sum_{n=1}^\infty n x^n=\frac{x}{(x-1)^2}$$  Why isn't it infinity?


A triangular number is a number that is the sum of the natural numbers up to some $n$. The closed form is $x = \frac{n(n+1)}{2}$. How do I get $n$ on one side? I've been looking at it from every angle, and I can't find out how. Any help?

There exists a formula for the $n$th term of this sequence  from the OEIS ("$n$ appears $n$ times") $$1, 2, 2, 3, 3, 3, 4, 4 ,4, 4, 5...$$ which is $$\left \lfloor \frac {1+\sqrt{1+8n}}{2} \right \rfloor.$$  Is there a better formula for the $n$th term? A formula that isn't a 'magic' one that just happens to work but one that comes from a well-founded observation. Preferably one not using the floor function. I also have suspicions about the sustainability of the above formula as I feel with very $n$ it may not function properly.


My sister's old work laptop is finally showing signs of aging, and she wants to reformat it to start over.  It's running a Windows 7 Pro (OEM) that she bought herself, as the laptop previously only came with a trial version of Home.  So, my question is, what would happen on activation? Would Windows 7 have installed the key onto her motherboard and she doesn't need to re-enter the key?  Or if she does need to re-enter the key, what would happen? Would it just work? Do we need some activation procedure?  We can't really do the phone activation as a.) We don't have a phone b.) We're in the Philippines

I purchased a laptop with with Windows 7. The OEM did not provide the disc, but there is a Windows installation with a recovery partition. The Windows 7 machine has not been setup or activated.  I need to install a different operating system for testing. Installing the new operating system side-by-side will cause more trouble than its are worth, so I am going to install the new operating system over Windows 7. That is, I am going to "blow out" the existing Windows 7 installation.  Later, I may want to be able to revert to Windows 7. My question is, how do I backup the current Windows 7 installation, without setup or activation, so I can use it again in the future, if desired?    Many existing questions and answers, like ,  and , presume the machine is setup. (I don't have an HP but I expect the process is similar).  I am trying to avoid the setup process because I want the "cleanest" untainted image as possible.    And so I am clear on what I am asking: I am looking for specific instructions, and not vague advice. For example, call out a tool you have used, and provide the two or three steps needed.  Sorry about this item. Without it, its seems like (1) the question could be vague or broad; and (2) I might create a useless backup image that does not restore (and I won't find out until sometime in the future). And testing a broken backup image will blow out things without a way to restore.


Every once in a while when I get a fatal PDO error, Drupal outputs the page without the theming and outputs the error message onto the screen. On my production site, it just outputs the page without the error message since I've disabled error reporting in php.ini. Still, I'd like that ugly looking themeless page on my prod site to be themed and informs users an error has occurred and assure them it is reported to the webmaster.   I tried creating a maintenance-page.tpl.php and maintenance-page--offline.tpl.php files and placed them in my general theme folder where all the other templates are, but it doesn't seem to get called. I also set error reporting to "none" in the admin/config/development/logging but it still outputs the error.   Any pointers would be greatly appreciated!!

What would be the best practice for theming the maintenance mode page in Drupal 7?


I understand, I think, the argument that the position is based on. Said in a sentence, the 15Bly's is in the temporal dimension only therefore space drops out because the redshifting absorbs the interim expansion of space which maintains a constant $c$ throughout. When the measurement is not in terms of time but in terms of distance the redshifted component of light must be translated back to distance and added to the initial displacement.  I get the reasoning to the extent my explanation says I do (it might be wrong and if so please treat it as the first part of my question). I accept that the reasoning itself is self-consistent and that the conclusion reflects a  legitimate way to look at things.   But despite trying quite hard, I haven't yet been able to see that this view merits its advancement from supplementary/alternative view to the primary view, displacing the observable physicality in the process. Let me briefly provide a little illustration.   Currently the number given to what is explicitly described as the observable or visible universe is ~50 Bly. As it is stated surely it is a false statement, for the physicality of what we see in the telescope, across the board is the universe as if no interim expansion ever happened.   This issue is not whether a larger universe can be anticipated, but whether the interim expansion merits being moved over from the unobservable-but-anticipated universe into the actual visible universe.   Surely that is a mistake, since the interim expansion is no more visible than any other region in the unobservable universe. It's not in our light cone.   So can anyone explain what is going on for me? It doesn't appear legitimate to cite redshift as the physical justification, because for one thing it has been known since Maxwell that redshift and time are mutually small 'r' relativistic. When we look at a high redshift galaxy, time is slower in the observed galaxy relative to the observer time from the perspective of the observer. That's surely the primary physicality, and not the view that adds the interim expansion. Not because the expanding universe is not the best explanation but because the interim expansion is outside our light cone.

The observable universe is approximately 13.7 billion years old. But yet it is 80 billion light years across. Isn't this a contradiction?


So this is how it looks when I get a preview rendering in the 3D viewport:     This is how it looks when I press render for a final result:     I have no idea what's happening. Can someone help me figure the problem out?

Why is the selected object displaying in the 3D view, but not rendering?  In object mode, it shows up:   However, it does not show up in render mode:   Why is this so and what causes it to hide in render mode?


\documentclass[letterpaper]{article}  \usepackage[T1]{fontenc} \usepackage[sc,osf]{mathpazo}  \begin{document}  How do I type ® under mathpazo?  \end{document}   This piece of code interprets    I thought it was about encoding, so I make \usepackage[T1]{fontenc} to \usepackage[utf8]{inputenc}:  \documentclass[letterpaper]{article}  \usepackage[utf8]{inputenc} \usepackage[sc,osf]{mathpazo}  \begin{document}  How do I type ® under mathpazo?  \end{document}   I get nothing:    I would like to have the number, alphabet and equation under mathpazo but how do I type special character like ®? Do we have encoding other than fontenc and inputenc?

I just don't seem to get it. So I come from the german speaking part of Switzerland and naturally I need ä ü ö a lot when I write german texts. So in LaTeX I have the option to go via  "a "u "o  which isn't really comfortable, or I can use an additional package. So now the confusion starts. I can use either  \usepackage[T1]{fontenc}  or  \usepackage[latin1]{inputenc}  So now if I create a new document and save it as a latin-1 encoded .tex file it seems it doesn't matter which option I chose they both work. Now why should I pick one over the other or use both? Which problems could occur (Do they occur if I use the same .tex file on another OS depending on which option I have chosen?)?  If I save the .tex encoded as lets say the mac os latin then the first option compiles but shows the wrong characters for the ä ü ö's. Is it then like latex maps the ä according to the latin1 to a character and since the document is encoded as something different than latin1 then gets encoded to something different again?  So if the last 2 paragraphs have been confusing (mainly because I'm confused) the main question is: What does fontenc what inputenc doesn't do and vice versa?


How can i use an api java for converting wav files to mp3 files without installing anything ? I tried JMF but it need to install JMStudio, and the broblem is that i need to not install anything. Who can give me an advice about something pure java !

I need an OpenSource API in Java, which can encode *.wav and *.au formats to MP3 and vice-versa.   I have evaluated Java Sound API and , but they do not meet my requirements and are not stable, respectively. Please suggest one that is free and platform independent.


How do I achieve this effect where that small part in "N" is taken out? I can use Sketch, Illustrator, Photoshop.  I can apply divide effect fine...    BUT when i start deleting the white block, this is what i see...      I wonder if that's b/c I added stroke to the text....?  How to fix it???

How come pathfinder - minus front is not working? I want a stylized N where that white part is taken out


I have just downloaded and installed Ubuntu 20.04.2 on my personal computer. I used Ubuntu 18.04 for 2 years and was happy with it but thought that it was time for an update. I downloaded Ubuntu from  and used the 'startup disk creator' app to burn the .ISO file into a usb stick. After installing Ubuntu, I noticed that I cannot drag and drop files directly into the desktop. I drag and drop between folders, but not directly to the desktop. Is this behavior normal? Is there any way to get this feature working again without having to replace nautilus? Best Regards!

In Ubuntu 20.04, on the desktop, there is a number of actions I wish I could do, such as, by order of importance :  use keyboard shortcuts such as select all, copy / paste. use drag & drop with icons deactivate the "mouse over" highlight, and restrict the clicking area to only the icon, not the surrounding square  To put it simply, I'd like to have the exact same features as offered by the desktop of Ubuntu 18.04 (probably related to a specific version of GNOME, and not Ubuntu itself). Am I missing something obvious here? I actually see no reason why those actions are removed or deactivated on the desktop, since they all work in any Nautilus window.


So I'm working on a web scraper function to get movie data from IMDB. While I'm able to get the data I need into a dictionary, because of how I've written the function, it appends a list of lists to the dictionary. I would like to return a single list. So right now I'm getting dict_key: [[A,B,C,D],[E,F,G,H],...] and I want dict_key: [A,B,C,D,E,F,G,H]. Eventually, I want to then take this dictionary and convert it to a pandas dataframe with col names corresponding to the dictionary keys. Here is my function: It takes a list of URLs, HTML tags, and variable names and gets the movie category(s), year, and length of movie. def web_scraper(urls, class_list, col_names):     import requests             # Import necessary modules     from bs4 import BeautifulSoup     import pandas as pd          class_dict = {}     for col in col_names:         class_dict[col] = []          for url in urls:         page = requests.get(url) # Link to the page         soup = BeautifulSoup(page.content, 'html.parser')   # Create a soup object              for i in range(len(class_list)):      # Loop through class_list and col_names             names = soup.select(class_list[i])  # Get text             names = [name.getText(strip=True) for name in names]   # append text to dataframe             class_dict[col_names[i]].append(names)          for class_ in class_dict:        # Here is my attempt to flatten the list         class_ = [item for sublist in class_ for item in sublist]              return class_dict

What's the difference between the list methods append() and extend()?


I am very new to database design. I have a task to create an inventory program with  asp.net core and entity framework core.  The inventory program will be used to manage various kind of products. Products have some common fields (aka columns) such as:   ProductId Contidion (new, 2nd hand) Price  etc   But each product also has some specific fields. For example, a mother board has   MemorySlots (either 2, 4, etc) MemoryType (DDR2, DDR3, etc) CpuType (Amd, Intel) etc   Another product, for example, is a book. It has:   ISBN Authors  Title etc   Question  How can I manage the product-specific fields in a database?

What would be the optimum design/structure for product data database, where each product have many variations and many attributes? Attribute sets vary between products, and some attributes have values common for all variations of a given product. A typical example of product variations & attributes table is in the image below:    (The 'ATTRIBUTE X' is here to give you and idea of a different attribute type than for 'Product 1').   Would it be practical to try to 'group' some of the attributes (to save time and minimise errors when creating new product entries)? If so, how complicated would it need to be?  If it's relevant - I'm thinking of using mySQL engine, but I'd be happy to see any applicable example from other engines.  EDIT : More information: at the moment we have over 400 variations in a spreadsheet, each one about 15-20 attributes, so that would give about 6000-8000 'data points'. It would be great to be able to list all possible values for a given attribute (to create a dropdown menu when adding new entries), and also to have a choice of possible attributes for a given product. It would be great to be able to specify which attributes are applicable for product variations of each product.


We were not planning on getting pregnant so we both were not practicing healthy living habits! The only time  we were not careful having sex was only a few days (2days) after my last period which I knew was not in the fertile range. But that only time got me pregnant.  We are over the moon but so worried as I have been consuming alcohol pretty much 2 weekends last month (not excessive but some shots) and I smoked weed like every day but not excessive only a small amount like one of two puffs a day but that was mixed with tobacco. Also two weeks after my last period we partied and I had half an ecstasy too. Had I known I was pregnant I would have never touched any of those! I love kids, they are my favorite but I'm so upset without knowing I might have caused damage to my baby!   Please advise! I'm in to the 5th week now and from the moment I knew I was pregnant I stopped all and I started eating and drinking a lot of water, taking vitamins needed etc. But I am still worried of the substances I may have put in my body without knowing I was pregnant.

My wife and I didn't know we're pregnant and in a weekend fun with friends we smoked a bit of weed - we don't usually smoke weed or cigarettes.  This is not something we're regulary doing as I said, but how bad to the fetus can it be ?


. . What I don't know is what will happen in 4 years from now (if my maths aren't that bad, 2017) when there are no more letters in the alphabet for the codenames. Will it goes backwards (ie. XYZYXW)? Will start over from A? Will use combinations (AB, AC, AD...), like Amourous Bosnians?  Did anyone get a wind of this?

The last release was Natty Narwhal (Letter N) for the 11.04. Then it was Oneiric Ocelot (Letter O) for the 11.10. This time, the newest one will be Precise Pangolin (Letter P) for the 12.04.  At this pace, what will happen when Ubuntu gets to Z? Will it start with numbers (007 Edition), will it start with double letters (AA Battery), or will it start from the beginning (Amazing Apple)? What will happen?


I'm sorry if this seems like a trivial question as I'm very new to linux. Anyway, I need to record the time for executing a shell script I made. time ./executable_file <input_here> > time_elapsed.txt   But obviously this only gets the output of the script I made. Any way on how to do this? update: So what I did was do the GNU version to get an output file for it. It worked now.

I am trying to time something using:  /usr/bin/time myCommand   However, since /usr/bin/time writes to stderr, if myCommand also writes to stderr, I will get more than just time's output on the stream. What I want to do is, redirect all of myCommand's output to /dev/null, but still write time's output to stderr. Using an example myCommand that writes to stderr of ls /nofile, we see that (obviously) there is no output at all with the following:  $ /usr/bin/time ls /nofile 2> /dev/null $   Without any redirection, we see both the output from ls (to stderr) and the output from time (also to stderr):  $ /usr/bin/time ls /nofile ls: cannot access /nofile: No such file or directory 0.00user 0.00system 0:00.00elapsed 0%CPU (0avgtext+0avgdata 3776maxresident)k 0inputs+0outputs (0major+278minor)pagefaults 0swaps   What I want is something that simply produces:  $ /usr/bin/time ls /nofile > RedirectThatImAskingFor 0.00user 0.00system 0:00.00elapsed 0%CPU (0avgtext+0avgdata 3776maxresident)k 0inputs+0outputs (0major+278minor)pagefaults 0swaps   Any ideas?


I am confused on what I have read about the Mann whitney test. We are testing whether our actual data is the same as our projected data. We had been using the t-test until we realized the data might not be normal and we are using ~12 observations per sample. Therefore I started using the Mann Whitney test.   I have read some places that the test is not appropriate unless the variances are equal, and other places have said you can still use it if you don't care if the shapes are identical.   So do I need to test each sample against the other to see if the variances are equal? Do the interpretation of the results differ if the variances are not equal?

The Mann-Whitney test requires homogeneity of variance if a median difference is suppossed to be statistically significant.  In case homogenity of variance is not met, but the test is significant:  Which aspects of the test can I report?


I have windows 7 installed in my laptop. I have a lenovo G570 series laptop. I would like to install ubuntu. Can anyone tell me which version to install ( 32-bit or 64-bit and 12.04 or 13.04)

I'm thinking about installing Ubuntu Desktop, but I don't know what flavor is the best for my system. What are the minimum and recommended hardware requirements? What kind of CPU? How much memory? Should I have Hardware Acceleration? What flavor should I use?  This is an attempt of a canonical answer. My answers have the "official  requirements", the recommended are a mix of official sources and opinion based (along with the answer it's told the source). You can comment or edit if you feel that the information is obsolete or incomplete. It is a good rule of thumb that any system capable of running Windows Vista, 7, 8, x86 (Intel) OS X will almost always be a lot faster with any Ubuntu flavor even if they are lower-spec than described below.


I have just started using my bike casually for exercise and wanted to know the Gears, Front gears 1-3- Back gears 1-7, When do i switch from downhill to uphill? I was told to keep on 3 Front ad back gear from 2-3 depending up or down hill, and getting the speed i need, not to over work my legs?

I've recently started commuting with a bicycle (Giant hybrid bicycle).  I've been trying to learn a little about bicycling to make my commute easier and my time on the bicycle more enjoyable.  Please forgive me for using the wrong terminology.  I've read that I should keep my pedalling speed mostly consistent and use my bicycles gears to adjust my speed.  The problem I'm having is understanding the 'how'.  My bicycle has 3 gears on the front of the chain and 8 gears on the back.    Low gear == easy to pedal High gear == harder to pedal  What I've found is that the gears don't follow a very logical (to me anyway) progression and because of that - I don't know how I should be shifting.  Currently, I've been keeping my front gear in the middle and using the back shifter to change between gears 3-7 or so.  I'm only use about four gears on my '21 speed' bicycle!  I'm also pretty sure the salesman said it was a 21 speed bicycle - but by my count there are 24 combinations.  I know (now) that I'm not supposed to have the front gear in the lowest position and the back gear in the highest (and vice-versa) but that seems to leave 22 gears.  How should I be shifting?  Should I really use all 21 or 22 gears?  I haven't done the math but it really feels like there is a big amount of overlap between the gears.  I hope this ascii art will make sense to someone.  This is just how it 'feels' to me.  ----1----2----3----4----5----6----7----8---- ------------1----2----3----4----5----6----7----8---- --------------------1----2----3----4----5----6----7----8----   Does that make sense?  Is it right?  It feels like there is overlap between the three front gears and that to shift the most 'smoothly' I'd need to constantly change both gears.  But this seems really complicated to me.  I've ridden bicycles with only three gears and I found myself thinking 'More would be nice' - but now I'm overwhelmed.  I'm also questioning if anyone really benefits from so many gears?!


Screen Time on my iPhone 8 (iOS 14.2) is reporting that the Wikipedia app has been running 24hrs a day for a few weeks. I don’t even have the Wikipedia app installed on my phone. What’s going on and how can I fix it? I’m trying to use Screen Time to limit my usage, but now the statistics are completely messed up.

Under , the report for the time spent on my phone is 1 hour 5 minutes. However, when looking at all the apps used, the time spent on the phone adds up to about 28 minutes and not 1 hour 5 minutes. Time spent on iPhone for the full day:  But looking at all apps, the time spent is about 28 minutes    How is Screen Time calculated?  Why is time spent on the iPhone calculated to  1 hour 5 minutes if time spent on all apps is really about 28 minutes?    Note:  I'm using ios v14. iPhone SE 1st Generation. The iPhone is supervised, (but I don't see why that would matter). Share Across Devices is enabled, however, I don't own or use any other apple devices besides this iPhone (seemingly this shouldn't either matter).


I've made a classroom scene in 3dmax and exported it(*.fbx) to import in Blender.  After importing it, when I edit it I found that there are two kinds of edges.   Picture's here.     What's the meaning of the green colored edges? Why some of edges are colored while others are not?   Due to Liked answer, I understood the meaning of colored edge.(question 1)  But still I don't know why colored edges(blue edge = sharp edge) exist in my work.(question 2)  I just exported a scene from 3dsmax and imported it to blender.   As you see in my picture, some of blue line need not be sharp, and I did nothing with it to be sharp.

There are red and pink edges on my mesh.  What do these colored edges mean? How can I use them?


From what I'm understanding, the Speed of Light is roughly 186k MPS NO MATTER WHAT!  Then say if a bean of light shoot pass near a Black Hole (Outside the Event Horizon of course) 1k lightyear away to us, it will take 1k year for us to reach us.  But because of the Gravitational Time Dilation, a year near a Black Hole will be a thousand year for us, so for some observer near the Black Hole, the same light reached us in only a year! Thus it had traveled at the speed of 10c!  Then if the Speed of Light is STILL 1c for the observer near the Black Hole, then it would be seem to us only travel at .1c!  Theoretically the light will take a thousand years to reach the destination for both observers, but a thousand Black Hole years will be a million years for us!  Unless for the Black Hole observer, we are only "a light year" away!  I can't wrap my head around this! Somebody PLEASE be so kind and explain it for me!  Much much appreciated!!!

Regarding the paper, what does Einstein means when he says:     "If we call the velocity of light at the origin of co-ordinates $c_0$, then the velocity of light $c$ at a location with the gravitation potential $\Phi$ will be given by the relation: $c = c_0\cdot\left(1+\frac{\Phi}{c^2}\right).$ The principle of the constancy of the velocity of light holds good according to this theory in a different form from that which usually underlies the ordinary theory of"   relativity"   Does the velocity of light is constant only into a space where the gravitation potential is constant either?


For a Python substring, I'm confused on defaults of x,y when z is negative Next lines: the defaults for x:y are no problem understanding because z is positive alpha = "abcdef" print(alpha[0:6:1])  #abcdef print(alpha[::1])      #abcdef    defaults for x,y change this to [0:6:1]  But when change to a negative z I'm confused. I would think [::z] becomes [0:6:z] regardless of z being +1 or -1. But seems defaults for x,y are different when the z is pos or neg print(alpha[0:6:-1])   # (no defaults example) prints nothing - OK print(alpha[::1])      # abcdef    default [::1] becomes [0:6:1] - OK print(alpha[::-1])     # fedcba    default [::-1] not becomes [0:6:-1] - why different x,y defaults?  Response to suggested duplicate I don't think this is a duplicate - the other question is about negative x,y. This questions is about x,y defaults when z is negative. This question involves a double colon syntax - that does not appear in the "duplicate question" reference.

I am a newbie to Python and have come across the following example in my book that is not explained very well. Here is my print out from the interpreter:  >>> s = 'spam' >>> s[:-1] 'spa'   Why does slicing with no beginning bound and a '-1' return every element except the last one? Is calling s[0:-1] logically the same as calling s[:-1]? They both return the same result. But I'm not sure what python is doing exactly. Any help would be greatly appreciated.


I work in mysql, and using hibernate criteria to build query. But I don't know how to get sql query from that criteria, so any one can help me, that could be grate, many thanks ?  tungosper

Is there a way to get the (to-be-generated) SQL from a Hibernate Criteria?  Ideally, I would have something like:  Criteria criteria = session.createCriteria(Operator.class);  ... build up the criteria ... ... and then do something like ...  String sql = criteria.toSql()  (But this of course does not exist)   The idea would then be to use the SQL as part of a huge 'MINUS' query (I need to find the differences between 2 identical schemas - identical in structure, not in data - and the MINUS is not supported by Hibernate)  (BTW I know I can check the SQL from the log files)


Sorry if this question has already been asked I just can't find how to do it in my problem.  I imported a file with a list of numbers from 1-20 into a listbox and then displayed the total amount of values and average into textboxes. I'm getting the right calculations it's just I have no clue how to convert them.  My code is:  int i = 0; int result = 0; while (i < lstbxDisplayInfo.Items.Count) {    result += Convert.ToInt32(lstbxDisplayInfo.Items[i++]); } //Displays average. txtAverage.Text = Convert.ToString((double)result / i); //Displays Amount. txtAmount.Text = Convert.ToString((double) i);   my output is:  Average: 10.5 Total Amount: 20   I need the output to be:  Average: 10.50 Total Amount: 20.00

When displaying the value of a decimal currently with .ToString(), it's accurate to like 15 decimal places, and since I'm using it to represent dollars and cents, I only want the output to be 2 decimal places.   Do I use a variation of .ToString() for this?


My problem relates to the "and graduation" part of the title below and would like more space between the two lines in the title. I'm using a template, could it be that that the "vertical space" between the lines was set in the thesis.cls file? If there is a quick/easy 'hack' to put in the preamble, that would also be appreciated.    My code is as follows:  \documentclass[a4paper, 11pt, oneside]{thesis} \begin{document} \frontmatter      \begin{titlepage} \newcommand{\HRule}{\rule{\linewidth}{0.5mm}}  \center    %--------------------------------------------------------------------------------------- - %   HEADING SECTIONS %---------------------------------------------------------------------------------------- \begin{center} %\includegraphics{UCT} \end{center} \textsc{\LARGE University of Cape Town} \leavevmode \\[1.5cm]   %---------------------------------------------------------------------------------------- %   TITLE SECTION %----------------------------------------------------------------------------------------  \HRule \\[0.5cm] { \huge \bfseries The Determinants of Student Retention and Graduation}\\[0.4cm] \HRule \\[1.5cm]  %---------------------------------------------------------------------------------------- %   AUTHOR SECTION %----------------------------------------------------------------------------------------  \noindent \begin{minipage}{0.3\textwidth} \begin{flushleft}  \large \emph{Author:}\\ Christopher \textsc{Rooney}\\ % Your name \href{mailto:chris.rooney1@gmail.com}{chris.rooney1@gmail.com} \end{flushleft} \end{minipage} \hspace{\fill} \begin{minipage}{0.5\textwidth} \begin{flushright}  \large \emph{Supervisor:} \\ Dr.\ Corn{\'e} \textsc{Van Walbeek}\\ %Supervisor's Name \href{mailto:Cwalbeek@gmail.com}{Cwalbeek@gmail.com} \end{flushright} \end{minipage} \\ [2cm] \begin{center}   {\large A thesis submitted in partial fulfillment for the\par}   {\large degree of Masters in Applied Economics (Development Stream) \par}         \bigskip         \bigskip         \bigskip         \bigskip %---------------------------------------------------------------------------------------- %   DATE SECTION %----------------------------------------------------------------------------------------  {\Large \today \par}  %----------------------------------------------------------------------------------------  \vfill % Fill the rest of the page with whitespace \end{titlepage} \end{document}

Why linebreaks break the line height within certain environments with size-changing macros?  I'm trying to understand what's the difference between these three approaches:   \newenvironment between {} or \begingroup/\endgroup inside a minipage     \documentclass{article} \begin{document} \thispagestyle{empty} \section{With newenvironment}  \newenvironment{env}{\begin{center}\LARGE}{\end{center}} \begin{env}   Text with\\linebreak \end{env}  \section{With begin/endgroup}  \begin{center} {\LARGE Text with\\linebreak} \end{center}  \begin{center} \begingroup \LARGE Text with\\linebreak \endgroup \end{center}  \section{With minipage}  \begin{center} \begin{minipage}{\textwidth}\centering   \LARGE   Text with\\linebreak \end{minipage} \end{center}  \end{document}


Let's asssume we have a wormhole that allows sending info to the past and receiving information from the future.  Next, we have a particle moving in two dimensions, for which we can evaluate $ p_{y} $ and $ x $ at every instant of time.  Also we can receive from the future the values of $ p_{x} $ and $ y$, so we can know without uncertainty the values $ x, p_{x}, y , p_{y} $. It is an apparent violation of uncertainty principle ??, or not ? :)

My layman understanding of the Uncertainty Principle is that you can't determine the both the position and momentum of a particle at the same point in time, because measuring one variable changes the other, and both cannot be measured at once.  But what happens if I measure a charged particle with any number of detectors over a period of time? Can I use a multitude of measurements to infer these properties for some point in the past? If not, how close can we get? That is, how precise can our estimate be?


I have a problem with calculation the center of mass of 20-dimension particles, some thing like this: A = [1 6 8 54 6 8 5 4 8 9 6 4 7 9 6 6 3 8 43 9] , Mass = 0.25 B = [2 6 3 4 6 8 4 4 8 5 6 4 2 2 6 6 3 8 1 1] , Mass = 0.6 C = [4 3 4 53 6 2 5 21 8 1 6 2 37 2 6 2 3 1 43 9] , Mass = 0.05 Could anyone guide me to find the solution for center of mass in each dimension (x1, x2, ... x20)? Thanks

Is it possible to calculate the center of mass for some 20-dimension ($x_i, i=1,\ldots,20$) particles? If it is possible, how can I do that?


Let $$f(x)=\frac{\sin\left(\frac{1}{t}\right)}{t}.$$   Show that $\int^1_0 f(x)\,dx$ exists but $f\notin L^1$, i.e., on $(0,1)$ $f$ is  improperly Riemann integrable but not Lebesgue integrable.  Attempt:  Affirmation: $\int^1_0 f(x)\,dx$ exists (I am not very sure how to prove this either).  Now, using the following      Theorem: $f\in L^1 \iff |f| = f^+ + f^- \in L^1$   I can reduce the proof that $f\notin L^1$ by showing that either $\int^1 _0 f^+\,d\lambda = \infty$ or $\int^1 _0 f^-\,d\lambda = \infty$, but I haven't been able to show this either.

In  wikipedia article for improper integrals,  $$ \int_0^{\infty}\frac{\sin x}{x}dx $$ is given as an example for the integrals that have an improper Riemann integral but do not have a (proper) Lebesgue integral. Here are my questions:   Why does this one have an improper Riemann integral? (I don't see why $\int_0^a\frac{\sin x}{x}dx$ and $\int_a^{\infty}\frac{\sin x}{x}dx$ converge.) Why doesn't this integral have a Lebesgue integral? Is it because that $\frac{\sin x}{x}$ is unbounded on $(0,\infty)$ and Lebesgue integral doesn't deal with unbounded functions?


I just installed Ubuntu 12.04 over 10.04. It seemed to go OK until I tried running my updates. When I launch Software Center I get the following error message:  Items cannot be installed or removed until the package catalogue is repaired. Do you want to repair it now? Once Update Manager has finished the repairs, you can close it and return to the store.  So I hit repair and then I get this message:  Package operation failed The installation or removal of a software package failed.  So I hit OK and it goes back to the first error message And it just continues repeating those two messages. How do I fix whatever is broken? I reviewed answers for similar questions. I tried the suggestions in that link but they did not work. I tried to post the results but, being new to this system I am not allowed to post more than 2 links. However, it seems the crux of the problem is this: (Reading database ... 742676 files and directories currently installed.) Removing libxml-libxml-perl ... /var/lib/dpkg/info/libxml-libxml-perl.prerm: 11: /var/lib/dpkg/info/libxml-libxml-perl.prerm: update-perl-sax-parsers: not found dpkg: error processing libxml-libxml-perl (--remove):  subprocess installed pre-removal script returned error exit status 127 Errors were encountered while processing:  libxml-libxml-perl E: Sub-process /usr/bin/dpkg returned an error code (1)

After installing Microsoft Windows Compatibility Layer (meta-package) i receive an error   Item cannot be installed or removed until the package catalogue is repaired. Do you want  to repair it     Ok, I thought... I'll just click repair and be done with it. After doing so I receive another error.    The full text reads:  installArchives() failed: (Reading database ...  (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 212945 files and directories currently installed.) Unpacking libasound2:i386 (from .../libasound2_1.0.25-1ubuntu10_i386.deb) ... dpkg: error processing /var/cache/apt/archives/libasound2_1.0.25-1ubuntu10_i386.deb (--unpack):  './usr/share/alsa/cards/ICE1712.conf' is different from the same file on the system dpkg-deb: error: subprocess paste was killed by signal (Broken pipe) Errors were encountered while processing:  /var/cache/apt/archives/libasound2_1.0.25-1ubuntu10_i386.deb Error in function:  SystemError: E:Sub-process /usr/bin/dpkg returned an error code (1) dpkg: dependency problems prevent configuration of wine1.4-i386:i386:  wine1.4-i386:i386 depends on libasound2 (>= 1.0.23); however:   Package libasound2:i386 is not installed. dpkg: error processing wine1.4-i386:i386 (--configure):  dependency problems - leaving unconfigured dpkg: dependency problems prevent configuration of wine1.4:  wine1.4 depends on wine1.4-i386 (= 1.4-0ubuntu4); however:   Package wine1.4-i386 is not installed.   Package wine1.4-i386:i386 is not configured yet. dpkg: error processing wine1.4 (--configure):  dependency problems - leaving unconfigured dpkg: dependency problems prevent configuration of wine:  wine depends on wine1.4; however:   Package wine1.4 is not configured yet. dpkg: error processing wine (--configure):  dependency problems - leaving unconfigured dpkg: dependency problems prevent configuration of wine1.4-common:  wine1.4-common depends on wine1.4 (= 1.4-0ubuntu4); however:   Package wine1.4 is not configured yet. dpkg: error processing wine1.4-common (--configure):  dependency problems - leaving unconfigured dpkg: dependency problems prevent configuration of wine1.4-amd64:  wine1.4-amd64 depends on wine1.4-common (= 1.4-0ubuntu4); however:   Package wine1.4-common is not configured yet. dpkg: error processing wine1.4-amd64 (--configure):  dependency problems - leaving unconfigured   So I click OK and now I'm back to previous screen ("Item cannot be installed ...")  I click on cancel and go to the red circle on the top right on my screen and try to update from there and receive this error    After that I just get thrown these errors        So now I can't add or remove any programs on my system. Does anyone have any idea how to fix this?


I'm trying to list files from two different directories in an Android device in order to upload them to a server.   To do that, I'm getting the directory files under a File type and then throwing both listFiles() into correspondents File[] types.      String d1 = Environment.getExternalStorageDirectory().getPath()+"/Download/";     String d2 = Environment.getExternalStorageDirectory().getPath()+"/DCIM/Camera";      File DirDocuments = new File(d1);     File DirCamera = new File(d2);      File[] ListDocuments = DirDocuments.listFiles();     File[] ListCamera = DirCamera.listFiles();   I've tryed to merge then and uploadign using just a single "for" loop      List<String> listTemp = new ArrayList<String>();      for( int i=0; i< ListaDocuments.length; i++)     {             listTemp.add( ListaDocuments[i].getName() );     }     for( int i=0; i< ListaCamera.length; i++)     {             listTemp.add( ListaCamera[i].getName() );     }      File[] DirTotal = (String[]) listTemp.toArray(); //toArray gives Object[] and cannot be converted to File[], so I used String[]   But my app just stop and exits. What am I doing wrong?   Do anyone knows how can I merge ListDocuments and ListCamera into a single File[]?  Thanks in advance. (sorry about my typos and bad english)

I need to concatenate two String arrays in Java.  void f(String[] first, String[] second) {     String[] both = ??? }   What is the easiest way to do this?


This is a duplicate of a question I've already asked, but got no answer to. I would appreciated any help.

So far, I understand that I have to look at each Jordan block. How do I prove that for a Jordan block with a value of x, $J_n(x)$, the Jordan decomposition of $(J_n(x))^2$ is $J_n(x^2)$ ? I have a feeling this will lead me to the solution. Thanks for your time.


From the analysis of chirp from Ligo and some other similar detector it is possible to tell the mass but can we also find out how far away too? or we need to look up into the sky and compare the energy wavelength of photon vs standard candle? What if the source is binary blackholes merger in a bootes void like region of space?

To understand fully the importance of the recent observation I would like to know if it is possible to infer the distance or luminosity (in whatever wavelength, or say, the overall power) of the source (or those of the burst after merging) of GWs. This could locate the event by two independent measurements thus improve confidence on current knowledge of distance   A second question, if it makes sense and has an answer that does not require GR maths: how GWs decay (if they do) while travelling, and if there is any shift due to expansion of space. In my naive interpretation there should not be but I apply a very simple reasoning here (just consider "proper points" in space, the passing way should not change its frequency - Assuming  G wave are not single impulse but a frequency can be defined).


I am modeling liquidity variable, real money growth with real asset price returns. The former is I(1) and the latter is I(0). The objective is to see the predictive power and forecast. However, can we apply VAR if both the variables have a different order of integration?  Will using I(0) against differenced I(1) series be a correct approach? especially keeping in mind I need to check forecast power through rolling window and then forecast further?

I have 4 time series. One of them is stationary and rest of them are not. I need to find relation between them. I will use AIC to decide lag length.   Should I use VAR or VECM to find relation between them?  Will VAR or VECM give me relation in terms of equation which can be used for forecasting?  Do I need to perform Johansen's test of cointegration?  What good would it do?


I want that for a given number of system boots (say, 1 or 2 system boots), a message will appear.  I will store the message somewhere, maybe in a variable:  message='If you finished testing, make sure to remove the testing application.'!'  Notes:   I use Ubuntu server 16.04 and aim for a solution for GUI-less systems.  The purpose of the code is to have a nice way to remind myself of a certain task, if, for some reason, I didn't recall that it is a good time to do it. I assume I should store the variable somewhere "deeper" than RAM, maybe in a file I'll create for it, maybe another method. I'm not sure. Cron isn't good because it's repetitive, and not for a given number of executions. This is good in case you reboot / turn off / power outage --- you get a reminder for an important task.   Clarification  I tried to describe a case when a user turnes on the machine, and in the moment the primary prompt appears, along with it, will appear the message I mentioned.

I need my script to be executed a minute after each reboot. When I apply @reboot in my crontab it is too early for my script - I want the script to be executed after all other tasks that are routinely run on reboot. How might I run the script sometime after reboot?


I have a function that loads a page and add a new user.   I want to show an alert(); and redirect/load a different function to change the url.  I have used    <meta http-equiv="refresh" content="0;page.php"></meta> <script>   alert("Pergunta eliminada com sucesso juntamente com as respostas!"); </script   Thank you!

How can I redirect the user from one page to another using jQuery or pure JavaScript?


Google Webmaster Tools automatically associated your website with the TLD that you're in. This is nice if the website is targeted towards that country, but its not always the case. In some instances, they're used for vanity, and in some - they're meant for users all around the world.   For instance, I have a .ky domain - Webmaster automatically targets this to the Cayman Islands. However, it should be unlisted OR United States, but there is no option to override this.   We've done marketing, promotions, and partnerships to gain the majority US inlinks. The other sites (Europe, etc) all rel alternate back to the .ky site as US-en, but still - having issues with US ranking.   Is there any way to override this feature in Google Webmaster Tools? It's quite silly that you cannot edit it for its intended purpose and Google makes this assumption.

Because I'm still living like it's 2008, I run a website with a .in TLD. The website has nothing to do we India and does not target Indian users.  Unfortunately, when I go to Google Webmaster Tools I see that Google have locked my geotargeting status to India:    On the , Google state that:     Sites with country-coded top-level domains (such as .ie) are already associated with a geographic region, in this case Ireland. In this case, you won't be able to specify a geographic location.   This seems implausibly inflexible, so I want to know if there are any sneaky ways of removing auto-geotargeting, or changing it to a more appropriate region?


I am a beginner working on an android application in which i am stuck at comparing the value taken from previous activity and a variable initialized with the same value as the previous one.  This is the mainactivity code       String string="value";     reference.setText(string);//i am setting the value manually to Edittext            Intent i = new Intent(this,next.class);     String getrec=reference.getText().toString();     Bundle bundle = new Bundle();     bundle.putString("VALUER", getrec);     System.out.print(getrec);     i.putExtras(bundle);     startActivity(i);     finish();   This the next.class code             int i;             Bundle bundle = getIntent().getExtras();              String venName = bundle.getString("VALUER");                 if (venName=="value") {                     i=1;                     ...                   }   And  this if condition is not getting executed. Please 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 am a regular user of stack-overflow, i have seen members up voting small answers which takes minimum amount of time to identify the problem and solved, whereas the answers which took lot of effort and time receives only one or two up votes, sometimes there won't be up votes too.Why users are not willing to up vote answers which deserves upvotes?

Recently I answered two questions on SO: The  is a completely trivial answer to a really basic question (kind of "read the manual and follow the one liner example there"). On the other hand, my  is a much more complicated answer that requires much more specialized knowledge of a very specific domain (happens to be related to my PhD research).  Clearly, the first answer could have been given by many SO users - I just happened to be the first to pick up the glove on this question. However, this is not the case for the second answer.  In contrast, when it comes to reputation - the first answer instantly got upvoted (everyone can relate to a simple question/answer), while the second one - I don't believe it will get much upvotes...  So, life isn't fair: for the one answer that really very few people could provide (the second answer) and is much harder to find and get -- is not rewarded, while the trivial answer is rewarded fast and strong...  How can we amend this? How can we encourage rare and specialized answers for difficult and deep questions?  Do we want SO to turn into a pool of trivial and superficial questions?    Update: Thanks to many meta-users who took the time to read through this question and ponder its implication, both answers I used as examples got exposed far beyond their fair-share. So, despite the fact that my original claim that the specialized answer get less reps is no longer valid, this does not change fact that in general my claim is stil valid: specialized answers requiring expert knowledge will recieve less attention at first.    Bottom line: (following my wish to have some sort of ). Indeed it sometimes seems like life isn't fair, but this is only in the short term. In the long run high quality answers do get their proper credit and exposure and their fair share of reputation. The reputation system of SO works quite well balancing and accounting for many factors and parameters. It would require a really strong argument backed up with serious research to change this mechanism.   Thank you all for the lively discussion and for showing me that life is fair after all.


How do I get notification of new questions on particular subjects (e.g. JavaFX or something) sent to me? I presume there is such a mechanism. Maybe someone can show me a link. Thanks. I got a quick reply to this saying it was a duplicate. Went to the duplicate, didn't understand a thing. I got to the page saying "Favorite Tags". But I have absolutely no idea what to do next. I'm quite embarrassed asking this. But I have searched.

There used to be subscribe button in the popup window which appears when you hover the mouse over a tag. It then sent you a confirmation e-mail and later it was sending e-mail feeds when new question tagged with the tag appeared.  The subscribe button is not there anymore. How can I subscribe to the e-mail notifications?    Old duplicate question:


I've got an image floated left, and I want to vertically align some text to the image so that the text sits in the middle of the image.  Any ideas how it's done? I have tried many solutions provided on this site, but none are working for me.  As shown below,  does not work.    /* Limiting outter width to illustrate the problem */  .cart-helper-outer {   width: 200px; } /* Makes helper items full width */  .cart-helper-inner {   width: 100%;   float: left; } /* Displays image left of text */  .cart-helper-inner img {   max-width: 50px;   float: left;   margin-right: 2.5%;   vertical-align: middle; /* this does not work*/ } .cart-helper-inner p {   vertical-align: middle; /* this also doesn't work*/ }

Secure checkout with bank grade encryption

Secure checkout with bank grade encryption

Secure checkout with bank grade encryption

Why won't vertical-align: middle work?  And yet, vertical-align: top does work.   span{   vertical-align: middle; }
      Doesn't work.


I'm quite new to PlayOnLinux so I got really confused as I tried to install some of my Steam games. I'm using the newest version of this program. I installed Steam by selecting it from the installation list. Everything was installed and Steam runs fine. Now I've clicked on the "Install" tab and I've chose "Counter Strike: Global Offensive". PlayOnLinux opened an installer and added some things like DirectX and so on, but at one point it wanted to install Steam again and the Steam setup window opened. My problem is that I already have steam installed and skipping the setup causes an error... Does anyone know the correct way to add Steam games correctly?


System info:  Ubuntu 14.04 software RAID, no separate drive for OS  This is where the system crashes:  I am hoping for help recovering at least enough to copy the files off the system. Update: I feel like there are two answers to my problem; one is fixing the OS so that it will boot again and the second is copying the files off. As long as I can save my files I am happy.  I tried using the Advanced Options for Ubuntu to pick an older kernel and as far as I can tell this does not seem like it will work. I tried 20 or so older ones till I found one that would give me a different boot crash point but it still crashes. I can upload a screenshot if needed.  Second I looked at  This is giving me more questions then answers. They suggest to run commands but I am not sure where to run them. I tried it in what I think I can call the GRUB command line (hitting c while booting) and from Ubuntu installer disk using rescue broken system. I did not mount a drive. Both times I got an error.  Thinking just recovering the files must be a easier option I looked into using    I am thinking the reason I am getting stuck on these options is because it is a RAID. I am a little worried also that if I do this step wrong I might mess up my RAID making the problem worse. So I am assuming you will will need more information to help further but I am not sure what would help. Please let me know and I will gather the info. Do not see a way to put in my own answer to the question so adding it here. Solution: I booted up with KNOPPIX Linux Live CD in terminal type  SU mdadm --stop /dev/md0 mdadm --stop /dev/md1 mdadm --assemble --scan --force

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


How does one insert a newline character into a cell of an Excel spreadsheet?  Up until now I have been copying and pasting the newline from a spreadsheet that already has one.   I am using Office 2003 but I hope that the solution will not be version specific.  But there must be a 'proper' way to do it.

How do you enter a carriage return or CHAR(13) in a worksheet cell manually ? I'm not talking about a line feed or CHAR(10).  I've seen this in a file and the carriage return had a very weird effect on the cell contents, but I can't reproduce it manually.  UPDATE  There are very good answers about how to enter a line feed in an Excel worksheet cell, and actually one of them gave me an idea how to achieve what I wanted in the first place:  =A1&CHAR(13)&A2 'Then copy cell + paste values only back again.   I'll accept the one that updates their content to reflect this. However, it'd be nice to know whether there's an equivalent of Alt + Return to type a carriage return.