My question is similar to , but about the opposite situation. The author of that question assumes the enemies are aware of the party; in those cases, I prefer to use initiative as normal. I am focused on the opposite situation: the party has managed to ambush the entire group of enemies. If enemies did not notice the party, the party has time to set-up and choose whoever should start combat.  Very often my party comes up with interesting traps and ways to initiate combat. The problem is that in 5th edition, once the combat is initiated, everyone rolls initiative and the combat goes from there. Specifically, my issue happens when an entire group surprises the other. Here's an example:  The party is all hidden in the shadows. 3 ogres lurk in the campfire in front, and have not noticed the PCs. The plan is simple. Wizard opens the combat with Faerie Fire, and all the martials will have advantage on their attacks. A single round, at most two, should be enough to wipe these Ogres. What actually happens depends on initiative: everyone rolls initiative, Wizard is last. Ogres are surprised. Rogue and Fighter either move in to attack without advantage (and are possibly hit by Faerie Fire), or ready a single attack for after the Wizard has cast his spell. Ogres do nothing, since surprised. Wizard is last, and when Faerie Fire is actually cast, the damage output of this surprise attack is sub-par. If Wizard came first on initiative, the whole plan would be perfect.  The worst part of this is that there isn't even a justification for this happening this way. On a stand-off, initiative represents reflexes, and it works well. But here, it doesn't seem to make sense that, if all players are waiting for the Wizard to do something, that they will be hindered (no multi-attack, no off-hand attack, etc) if, for some reason, the Wizard rolls low. Narratively, they could just go "hang on, seems like the Wizard is distracted, lets remain hidden, and re-roll initiative". Initiative is an abstract concept, and during the actual combat, I'm fine with how it works, just not for this combat initiation against a surprised group.  My House Rule: When a group attacks a surprised group of enemies, everyone rolls initiative as normal. For the first round only, the attacking group selects an initiator to act before the highest initiative attacker, initiating combat. This initiator will not act in its actual initiative position on the first round, but will do so on following rounds. Example: Ogres have initiative 25, 20 and 15. Wizard has 5, Rogue has 17, Fighter has 22. With this rule, Ogre acts first, does nothing due to surprise, stops being surprised. Wizards is next, acting as combat initiator for the party, playing before the fighter in this round. Fighter is next, then Ogre (surprised), Rogue, and Ogre (surprised). In the following round, the order is Ogre, Fighter, Ogre, Rogue, Ogre, and finally the Wizard.  It is a simple change. The group initiating combat, because they have the upper edge and time to prepare, chooses a person to go first in the first round. After that, everything else is exactly as before. If it happened that this person actually had the highest initiative check, nothing would be different from normal. Thoughts on this rule? Would it imbalance things, or can it be taken advantage of somehow? I think it is a decent way to join narration, planning, and mechanic execution. It helps those parties relying on Assassin Rogues or on AoE initiators.

As a fairly new DM, one thing that has commonly occurred in my sessions so far is my PC's starting combat outside of initiative.  For example after a telepathic conversation with a Nothic was going south, my Rogue said 'I shoot him with my shortbow'. At the time I wasn't sure of the correct ruling for this situation so I allowed him to attack and then rolled initiative to start the combat proper. I ensured that the Nothic wasn't surprised though as it was clear that these were two hostile forces trying to work each other out.   Coming away from the session I knew this wasn't right and wanted to get the official answer before next time. I came across this question . The accepted answer here as per RAW is that after the Rogue announced his attack, everyone should roll initiative and if anyone of the party go before the Rogue, then they will just move and ready an action. However I don't like the sound of this as I believe it takes a bit away from the players agency of quick-drawing an attack before the other side has a chance to respond.  Therefore my idea is as follows. In this situation again, the Rogue attacks and then everyone rolls initiative. Then in the turn order, the Rogue skips this 'turn' in the first round as they have already taken it at the top of the 'round'. After the first round the Rogue's turn then falls back into place depending on their initiative roll.   My question. Is this balanced and practical? I know that as DM I have the authority to have this as a house rule. But I wanted to make sure that this is not over-powered and that it is not in conflict with any spells/feats/abilities etc. Will it work?


I am modelling 2D physics collision into simulations. In Physics for Game Programmers, Grant Palmer book,    the velocity Vn1 after collision is mentioned to be independent of the friction coeff. between the surface.   for a sphere Vn1=5/7Vn0. But this holds to true only when the sphere is assumed to be  in pure rolling after the impact.  How can i determine the velocity of the ball for a sliding case as well. I have to use it in a physics simulation and the duration of impulse is not known. Is there any other way to determine it?

The  characterizes a collision in one dimension by relating the initial and final speeds of the particles involved,  $$C_R = -\frac{v_{2f} - v_{1f}}{v_{2i} - v_{1i}}$$   In a 2D collision, the velocity can be split into components parallel and perpendicular to the "plane of collision" (the plane tangent to the two objects' surfaces at their contact point), and the equation above applies to the perpendicular components of the velocities only. One could write  $$\begin{pmatrix}v_{2f\shortparallel} - v_{1f\shortparallel} \\ v_{2f\perp} - v_{1f\perp}\end{pmatrix} = \begin{pmatrix}1 & 0 \\ 0 & -C_R\end{pmatrix}\begin{pmatrix}v_{2i\shortparallel} - v_{1i\shortparallel} \\ v_{2i\perp} - v_{1i\perp}\end{pmatrix}$$   My question is, is it useful (i.e. does it produce a more accurate description of realistic 2D collisions) to generalize that matrix? Perhaps by allowing the top left element to be unequal to 1, or allowing nonzero off-diagonal elements? Or is there some nonlinear relation that works better?  As usual, if you know of any relevant published research, references would be much appreciated.


Let $X_1,..., X_n$ be independent random variables with densities $$f_{X_i}(x|\theta)=e^{i\theta -x}$$ when $x \geq i\theta$. It's zero when $x > i\theta$. Prove that $T=\min_i (X_i /i)$ is a sufficient statistic for $\theta$. This question is from statistical inference, 2nd ed, by g. casella and r. l. berger CHAPTER 6 QUESTION 2.

I tried to do the following task:  Let $X_1,\ldots,X_n$ be a random sample with the pdf $$f_{X_i}(x|\theta)=\begin{cases}e^{i\theta-x},&&x\ge i\theta\\0,&&x<i\theta\end{cases}$$ Show that $T=\min_i \frac{X_i}{i}$ is a sufficient statistic for $\theta$.  First of all, I don't know what the notation $f_{X_i}(x|\theta)$ should mean. Does it mean that $f(x_1,\ldots,x_n|\theta)=\prod_{i=1}^{n}e^{i\theta-x_i}1_{x_i\ge i\theta ,\forall i \in\{1,\ldots,n)\}}$? (I plan to use the factorization theorem)


abstract class Library {   private String day;   public String getDay()   {     return day;   }   public void setDay(String oo){       day = oo;    }    public abstract String setDate(); }  class Books extends Library {   public String setDate() {     DateTimeFormatter formatter = DateTimeFormatter.ofPattern("d-MMM-yyyy");      String dat = this.getDay();     LocalDate localDate = LocalDate.parse(dat, formatter);      LocalDate when = localDate.plusDays(7);      String waitString = when.format(formatter);     return waitString;    } }  class Main {    public static void main(String[] args) {    for (int i=0; i<10; i++){         System.out.println(rent[i].getDay() + rent[i].setDate());    } }   Java gives me an Exception in thread "main" java.lang.NullPointerException from String dat = this.getDay();, but when I change it to like String dat = 23-Mar-2019it works fine. It seems like java is not responding to "this.getDay()" from the extended class, but I do not know how to fix this.

What are Null Pointer Exceptions (java.lang.NullPointerException) and what causes them?  What methods/tools can be used to determine the cause so that you stop the exception from causing the program to terminate prematurely?


I am using a regular expression to validate email addresses in an online form. A lot of emails are entered as such: www.test@example.com  How can I disallow the use of www. using regex? My current expression:  ^[\+_a-z0-9-'&=]+(\.[\+_a-z0-9-']+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,})$   I know this expression checks for a gTLD - we require an email address to have one.   EDIT: This question is slightly different to others I have found as I wasn't sure how to add the www exclusion in - that's all I needed.  Also, the target market we reach doesn't have the same experience using technology as most people do, so the amount of email addresses that we receive with www in them is massive. www.john@gmail.com is perfectly valid yes but it is 99% of the time not what the persons email address is. Our CRM system can't send emails to the correct people then.

Over the years I have slowly developed a  that validates MOST email addresses correctly, assuming they don't use an IP address as the server part.  I use it in several PHP programs, and it works most of the time.  However, from time to time I get contacted by someone that is having trouble with a site that uses it, and I end up having to make some adjustment (most recently I realized that I wasn't allowing 4-character TLDs).  What is the best regular expression you have or have seen for validating emails?  I've seen several solutions that use functions that use several shorter expressions, but I'd rather have one long complex expression in a simple function instead of several short expression in a more complex function.


I have downloaded a DTM and building heights from UK Digimaps (we have institutional access) and would like to: Export them to STL or other CAD format. Is it possible to do this in QGIS or do I need multiple programs? I haven't found any way of exporting to STL (dwg or other) yet.  Seems GlobalMapper is an option:  Isn't there a way in QGIS ?

I load an ASTER data to Global Mapper workspace and try to export to STL file, receive the message that I need a 3D vector file.   I tried all formats in GM, grid xyz, dem, contour in vector format and so on.   What kind of format file I need to convert ASTER data to export to STL file?   or even, PLY, OBJ,SKP, 3D formats?


I applied for a Visit visa and which in my my savings bank account i had Gh2700 cedis equivalent to 509.34 pounds which i also presented evidence of source of fund monies i receive from family and friends. My question is was my bank account savings money insufficient that made the ECO refuse my visit visa application describing my personal financial and economic circumstance.Hope to hear from you guys here

The UK Visas and Immigration Directorate publishes  that provides helpful tips that can result in successful visa applications. Section 2 of this guidance opens is entitled "other documents you may want to provide" (emphasis mine).  Section 2: other documents you may want to provide – all visitors This section provides guidance on the types of documents that you may want to provide to help us consider your application against the Immigration Rules. Previous travel documents/passports, which show previous travel. Financial documents showing that you have sufficient funds available.  These must clearly show that you have access to the funds, such as:  bank statements building society book proof of earnings such as a letter from employer confirming employment details (start date of employment, salary, role, company contact details) where a third party (who is either in the UK or will be legally in the UK at the time of your visit) is providing financial support to you e.g. a business, a friend or a relative, documents to show that they have sufficient resources to support you in addition to themselves and any dependant family should be provided   The first item is "bank statements" and this ties in with the , which says...  evidence that you can support yourself during your trip, eg bank statements or payslips from the last 6 months  (Note 'eg' is a Latin abbreviation meaning "for example"; this appears to be optional rather than a fixed requirement.) Question: How should someone interpret this such that the chances of success are maximized? How many statements should I submit? What are they looking for and what do my bank statements tell about me?


I have a list of 248 values that looks like this: lst = [10.0, 7.4, 8.2, 8.8, 7.4,.... ] I want to get the average of every 8 value. Such as it will be divided to 31 sub lists and will have the average of every list. This is what I have for now but I have to write this 31 times if I use this method. Can someone point me to an easier and more efficient way? num1 = 0 for i in range (8):     num += float(lst[i]) print(num1/8)   num2 = 0  for i in range (8, 16):     num += float(lst[i]) print(num2/8)

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


Casual LaTeX user here, so if something seems dumb/obvious, it probably is.   I'm want to use LaTeX (via pandoc) to create PDFs that contain hebrew characters.   I found  where someone appears to have solved a similar problem.  However, when I create a utf-8 text file (working.tex) with the same content  \documentclass{article} \usepackage{fontspec} \usepackage{polyglossia} \setmainlanguage{hebrew} \setmainfont{Times New Roman} \newfontfamily{\hebrewfont}{New Peninim MT} \begin{document} \title{שלום עולם} \author{שלום עולם} \maketitle  העיר מקודשת ליהדות, לנצרות ולאסלאם, והיוותה מרכז חיי העם היהודי בימי קדם ומושא געגועיו בזמן שהייתו בגלות. משום מרכזיותה בעולמם של המאמינים, הייתה העיר מוקד למלחמות וסכסוכים הנמשכים עד עצם היום הזה. מאז סוף המאה ה-19 התפתחו סביב העיר העתיקה שכונות העיר החדשה, המהוות כיום את רובה המוחלט של העיר. במרכזה של ירושלים השלמה עומד הר הבית, שמפריד בין מערב ירושלים למזרח ירושלים.  בשנת 1981 הוכרזה העיר העתיקה של ירושלים כאתר מורשת עולמית על ידי ארגון אונסק"ו של האומות המאוחדות, והיא נמצאת ברשימת האתרים בסיכון.   \end{document}   and then use pandoc to convert that to a PDF  pandoc --latex-engine=xelatex working.tex -o working.pdf    and then open the PDF     I get zero hebrew characters.    Is there anything wrong with the above document?  Are there common troubleshooting tips for getting hebrew working with LaTeX and pandoc?

Does anyone know why pandoc, with the xelatex engine might not generate hebrew characters while directly calling xelatex does?  That is, I have a simple .tex file with some hebrew in it.   \documentclass{article} \usepackage{fontspec} \usepackage{polyglossia} \setmainlanguage{hebrew} \setmainfont{Times New Roman} \newfontfamily{\hebrewfont}{New Peninim MT} \begin{document} \title{שלום עולם} \author{שלום עולם} \maketitle  שלום עולם  \end{document}   If I feed this to xelatex  $ xelatex simple.tex    I get a PDF file will hebrew characters. Yay!  However, if I feed the same document to pandoc, specifying the --latex-engine=xelatex engine.  $ pandoc --latex-engine=xelatex simple.tex -o test.pdf   I get a PDF with no rendered hebrew characters.  Does anyone know why this happens, and how I might fix it?  I assume pandoc is calling xelatex in the background -- is there a way to view which options/arguments/flags its invoking it with, or to clearout those options?  Also -- My ultimate goal is to convert an HTML document with some hebrew characters into a PDF file with pandoc and I run into similar problems when I have a file (simple.html) like
שלום עולם
   and then attempt to convert it  pandoc --latex-engine=xelatex simple.html -o test.pdf   The above also produces a hebrew-less file.   So, I'm using pandoc to convert to the simple.tex file as a debugging technique, not because I'm actually moving from tex to PDF.  I know I can invoke xelatex directly and get this to work, but for complicated reasons I'd like this working with pandoc.  I'd also like to understand how pandoc is actually interacting with LaTeX.  So bonus points for those sorts of answers :)


last day my pictures were deleted by mistake i have tried to acquire them back by simply logging into samsung account . How can i get my pictures back by using my samsung account ?

I accidentally deleted the entire "downloaded" album full of pictures from my Samsung Galaxy S2 (SPH-D710) and am trying to use a  I downloaded.  My phone will not show up as a remove-able storage device on my computer, or on the program. I have tried to change the USB settings on my phone but there is no USB settings when I go to Settings > Wireless and networks as most information instructs.   I found the setting for USB debugging by going to Settings > Developer options and can turn that on and off, but that is the only setting I can find relating to USB storage.   When I connect it to the USB cord it gives me MTP or PTP options but again no USB options.   Any advice??? Thank you!


Is it possible to view data of all subsites / sub project site from the parent site.  Example:  Project Site : ABC  Sub-Project sites:  1) xyz  2) pqr c) def  All the sub-project sites contains multiple lists.  Project owner would like to view selective content from all lists hosted in the sub-projects once logged on the parent site.  I`m not sure how it can be achieved. Please share relevant article that explains with examples if possible.

I have few sites in one of my site. There is a list, with same name say 'SOW' in all of these sites, containing site specific data. Now, at the parent site i want to see all the data at one place from the 'SOW' list in each of the sub-sites.  Below is the representation of what i mean.                                  A (Root Site)              A1(Sub-Site)  A2(Sub-site)   A2(Sub-site) A2(Sub-site)                    SOW(List)      SOW(List)      SOW(List)    SOW(List)   Now, at "A (Root Site)" i want to see all the data from 'SOW(List)' of each "A1(Sub-Site)",  "A2(Sub-site)",  "A2(Sub-site)" and  "A2(Sub-site)"  Basically, i want to know whether we have some Out of the Box solution for this scenario. If not, let me know some custom solution.  Thanks in Advance.


Do I have any support options after Spring 2017 when Ubuntu Linux 12.04 LTS Precise Pangolin is set to end of life?  I have a client needing extended support.

Not sure if there is a better communication mechanism for asking this question. Ubuntu 12 is EOL April 2017. Do corporations have any option to extend support on 12?  Thanks


I need ur help with this question.   The question states that: Use Induction TO Prove that   1*2+2*3+...+n(n+1) = n(n+1)(n+2)/3    So, so far I used to the basis step to show that this statement is indeed true.    For n = 1, we have 1(1+1) = 1(1+1)(1+2)/3  2 = 2  which is true    Now the Inductive Step:    Assume that P(n): 1*2+2*3+...+n(n+1) = n(n+1)(n+2)/3    Now from then I have no idea what to do. So can someone help me finish this unfinished question.  Thank You.

$$\sum_{r=1}^nr(r+1)=\frac{n(n+1)(n+2)}{3}$$  could you help me with how exactly I work this out?


I'm trying to set up an APT repository on my local network that will work similar to apt-mirror except, I don't want to mirror an entire repository, I only want to serve specific packages of my choosing. I need to be able to download the packages I want from the public APT repositories and serve them from mine. I've had a look into apt-mirror, apt-cacher and reprepo.   Apt-mirror doesn't look like it will work as it mirrors an entire repository and automatically downloads updates, which I want to do manually. Apt-cacher just caches packages downloaded by people on the network so that's not what I'm looking for either. Reprepro looks like it is what I want but I can't figure out how make it serve packages I download from public repositories. Everything I have managed to find uses reprepro to create, sign and serve your own packages that aren't in official repositories.  How would I go about setting this up and adding specific packages? I don't want to resign the packages myself, I would rather leave them signed by the public repository.  I would also like to control what happens if the client tries to install a package that is not in this repository, I'm not sure what exactly I want to do in this situation yet but I'm tossing up between blocking/disallowing the download, and redirecting them to the public repository.  EDIT: For this to work would I need each package to be set-up exactly the same as it is on the public repository? ie. Would it need to be in the same sub directories (stable, testing, main, contrib, etc) and have the same entry in the packages.gz file? If so, how would I find out all this information about the package and is there an automatic way to ensure it is correct in my repository? Much like apt-mirror/apt-cache how they automatically copy the official repo?

I would like to set up an APT repository on a server that will provide a couple of packages.  Is there a way to set one up without installing any software on the server?  How do the files have to be organized?    Edit: I must be doing something wrong... can someone please help me? I have the repository at   I'm not sure where or what, but something's misconfigured. I only currently have one package and it's for all architectures.  Here's what's been added to my /etc/apt/sources.list:  deb http://quickmediasolutions.com/apt stable main


I want to install Lubuntu on an embedded system. I can connect display and keyboard, but no mouse, so only CLI installation is possible. Although I need the complete (not server) distribution because I want to connect to the computer using VNC. Thank you for help.

I have a headless storage server with preconfigured Windows Home Server. How can I install Ubuntu without a display?  Do I have to build a custom install flash drive? If so, what would be the basic procedure? Is there a program (like unetbootin) to do this?


I wanted to use different funny mouse cursor pointer to my commercial website project. Is there any website providing this mouse pointer images for free or for low price?  If not how can i create a mouse cursor images myself. I guess its extension is .cur  I have little knowledge of photoshop and gimp tool. Can i create the mouse cursor pointers with this? If you can give a link to free cursor pointer images or tutorials to create this mouse cursor pointer, it will be much helpful to me. Let me know where should i start first.  Thanks

I'm using Photoshop CS4 and I need to create a .cur image.  The actual process of doing so is simple enough but I cannot find the necessary Photoshop CS4 plug-in to do so.  Can anybody help me either find the plug-in or show me how to create the .cur file without it?


I have just installed Ubuntu 14.04 yesterday and it worked fine but now the screen goes black at random times and I have to do a hard shutdown. does any one have any ideas.  I have a refurbished Lenovo t61 750gb hard drive 32 bit it is a dual boot with windows 7  The screen does not go blank but actually turns off but the stirs light I.e caps lock are still on

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


Say I'm in a hurry and I really need help to fix some code. I want to reach many people and get the best answer as soon as possible.  In this situation I would probably copy and paste the same question on a few good websites like Stack Overflow and .  Are there any consequences I might face for doing this, being reported for example, or is it perfectly acceptable and maybe pretty common?

I made a question at Stack Overflow long ago and also posted the same question in a non-Stack Exchange website (Xtreme VB Talk). The question .  According to the answer, I shouldn't have cross-posted between Stack Overflow and XtremeVBTalk, because     it increases the probability that wires will get crossed and everyone will waste time.   But I'm not sure why is that wrong. You see, I simply see Stack Overflow and XtremeVBTalk as two different communities with different users. So posting the question in both sites would just give me more answers. And if I got the answer in one of them, I would report back to the other site and let everyone know (and perhaps someone else would be benefited as well). I really doubt it is a waste of time - the more input, the better. The fact that someone was a user in both websites is simply a coincidence.  I realize that Meta Stack Exchange question  exists, but apparently it involves cross-posting within Stack Exchange sites, but this is about external websites instead.  I also realize that I was told that as "advice" (since my question was not flagged or anything), but well, I am now curious: Why would anyone consider this a bad practice?


I don't know how to write my own regex.     1 RULE: I want allow: a-z, A-Z, 0-9. new Regex("[^a-zA-Z0-9 -]");      2 RULE: I want allow char: +, -, |.   How can i combine 1st and 2nd rule?

I don't really understand regular expressions.  Can you explain them to me in an easy-to-follow manner?  If there are any online tools or books, could you also link to them?


How can i demonstrate the only matrix which commute with every matrix it's $aI_n$? Thanks so much. I have no ideea how can i demonstrate that, it's too obvious. :/

The question is from Axler's "Linear Algebra Done Right", which I'm using for self-study.  We are given a linear operator $T$ over a finite dimensional vector space $V$. We have to show that $T$ is a scalar multiple of the identity iff $\forall S \in {\cal L}(V), TS = ST$. Here, ${\cal L}(V)$ denotes the set of all linear operators over $V$.  One direction is easy to prove. If $T$ is a scalar multiple of the identity, then there exists a scalar $a$ such that $Tv = av$, $\forall v \in V$. Hence, given an arbitrary vector $w$, $$TS(w) = T(Sw) = a(Sw) = S(aw) = S(Tw) = ST(w)$$ where the third equality is possible because $S$ is a linear operator. Then, it follows that $TS = ST$, as required.  I am, however, at a loss as to how to tackle the other direction. I thought that a proof by contradiction,  ultimately constructing a linear operator $S$ for which $TS \neq ST$, might be the way to go, but haven't made much progress.   Thanks in advance!


I have just started studying implication in mathematics. So, you'll probably have an idea of where my confusion lies right from the get go.  In the truth table, where $A \implies B$ we obtain this result:  A   B   T/F ___________ T | T | T T | F | F F | T | T F | F | T   Now, my confusion here is regarding why $A\implies B$ given A is false, and B true. The others I understand. The first and last one are obvious, the second one implies, to me anyway, that given A implies B, the truth of B rests upon the truth of A, B is false, A is True, which cannot be, thus not B given A is false.  Now... then, why is B true despite the fact that A is false? Or rather, why is the statement B given not A, True. The truth of B is implied from the truth of A, but A is a false statement. So it's very contradictory that this may be, and in fact, if you go through a real life example, you would find that the third statement seems to be false.  Say $A$ is the statement that it is dark outside, and $B$ the statement that the sun is not on our side of the earth. If it is not dark outside, than stating that the sun is on the other side of the planet must be wrong (in my example i'm going to claim that the sun is the only light source).  Side note:  I just had a thought, if A is false, does that mean you can conclude... mmm, whatever? I mean, B is implied via the truth of A, if A is false, B is NOT implied, but then B could be EITHER true or false, I suppose. Is this correct?  However, would that not mean that A does not imply anything when false. Would that not set the 3rd and 4th statement to be undefined?

In propositional logic, the statement "If pigs can fly, then elephants can lay eggs." validates to true because the antecedent validates to false.  In other words, given $a \rightarrow b$, if a is false, the entire statement is true. Why?  Just because the antecendent is false doesn't mean that another fact depends on it, right?


I am working on an e-commerce website (similar to e-bay) where users can buy or sell products. The urls for buying a product are like: example.com/browse/cars example.com/browse/toys etc  And the urls for selling products are like: example.com/post-ad/cars example.com/post-ad/toys etc  When selling a product, user just need to fill a form and click on Save. Also user needs to be logged-in, in order to sell a product, therefore I have decided to prevent this page from being crawled and added the following to my robots.txt Allow: /  Disallow: /*/post-ad Disallow: /account/login?ReturnUrl=*  Now I am getting the following warning in Google Search Console, for of of the post-ad pages:  Indexed, though blocked by robots.txt  How can I resolve this issue?

Recently Google has been complaining about certain pages saying:  Indexed, though blocked by robots.txt   I am confounded by this error.  Yes the page, is blocked by robots.txt and it has always been.  Nothing new has happened and I don't want it crawled or indexed.  Why is google indexing the page when I explicitly telling it not to?  I realize I can add a meta tag like <meta name="robots" content="noindex"> but why should this be necessary?


I currently have Windows 7 installed on a laptop with Ubuntu 14.04 installed via Wubi. So when I boot up I have the option to load up either WIndows or Ubuntu. I am going to install just 14.04 on its own as my current (wubi) version is made up of lots of previous versions added on top of each other.  So I am going to back up my Home folder, put the bookable usb stick in with Ubuntu 14.04 on it and click the option to install alongside windows, during the install.   My question is will I need to remove the wubi version of Ubuntu, that I currently have or can I install the new Ubuntu (alongside Windows) and then remove the wubi version when I know all is OK?

I have installed Ubuntu on my D: partition using Wubi. Is there any way in which I can remove my Windows from C: drive and move my existing Ubuntu installation to C: drive and make it a regular install.


I just installed Ubuntu 12.10 on my Asus 1201N and Unity refuses to work after installing the nvidia binary drivers. It works fine on the default, but those are no where good enough when it comes to playing games. This is the output of unity_support_test:  Xlib:  extension "GLX" missing on display ":0". Error: GLX is not available on the system   I can't find any ways to fix this. The setup is as pure as possible with absolutely no additional software, so it can't be something I installed.  EDIT: Oh, and with the open nouveau driver, everything works fine. I'd like to run the nvidia driver though.

I have GeForce GTX 560 Ti. I's worked fine in 12.04 with nvidia drivers. Unfortunately, after todays 12.10 update, something broke down.   I've tried nvidia-current, nvidia-current-updates and nvidia-experimantal. Always the same behaviour: Bad resolution in lightdm, after logging nothing except wallpaper. No unity panels, "win" key doesn't work.   After removing nvidia drivers everything work.


I'm installing a Chilli hotspot on Ubuntu Server and I'm trying to use it with phpmyprepaid, but I can't get it working.  The Chilli part is fine, but i can't access the install of phpmyprepaid. I'm downloading it and unzipping in /var/www but it always tells me that it's not found.  Would anyone have an idea?

I recently installed Ubuntu 14.04, then I installed lamp-server and placed my webpages in /var/www directory, but when I opened localhost in the browser there was nothing. I think that happened because Zend updated Apache.  Whatever the reason may be, I want to know where to keep my php files so that I can access them from my browser.


The city of Haarlem (Netherlands) publishes all its open data through a . To examine if I can build an interesting application with it I would like to explore the data this service produces.  What I am looking for is software similar to generic SOAP clients, that lets me:   point to the service endpoint select an operation input request parameters perform a request show the response data   I have tried QGIS, but a fresh install of the current version produces an error about a missing qgis_core.dll. And I am not sure QGIS can do what I want, since I am not interested in visualizing the data at this moment.  I don't need a graphic viewer, but something that shows the actual requests and responses because I want to find out how to communicate with such a service in my own code.

I have the task to provide my point observations data in the "WFS 2.0" (Web Feature Service 2.0) standard format.  Are there any free, easy-to-use, desktop GIS clients or online viewers for showing and querying my WFS 2.0 layers?  I have only found the ""  Do any other popular free GIS viewers (Kosmo, MapWindow, ArcGIS explorer..) have support for showing and querying WFS 2.0 web feature service?


I am trying to prove that the polynomial $P = X^5 + X^2 + 1 ∈ F_2 [X]$ is irreducible.  What I did:  I showed that $X^2+X+1∈F_2[X]$ is the only irreducible polynomial of degree 2. Is there a way to use this to prove that $P$ is irreducible without checking all the polynomial products giving polynomials of degree $5$?  Many thanks!

Find all irreducible monic polynomials in $\mathbb{Z}/(2)[x]$ with degree equal or less than $5$.   This is what I tried:  It's evident that $x,x+1$ are irreducible. Then, use these to find all reducible polynomials of degree 2. There ones that can't be made are irreducible. Then use these to make polynomials of degree 3, the ones that can't be made are irreducible. Repeat until degree 5.  Doing this way takes way too long and I just gave up during when I was about to reach degree 4 polynomials.  My question is: is there any easier way to find these polynomials?  P.S.: this is not exactly homework, but a question which I came across while studying for an exam.


How do I highlight certain word using the cat command on the terminal?

I can do the following to see if some word is available in the output of "cat":  cat filename | grep word   This filters the output and shows only those lines which contain "word". Now, is it possible to only highlight the "word" in the output, without dropping other lines?


Let $(x_n)_n$ and $(y_n)_n$ be sequences in $\mathbb{R}$, such that $(x_n)_n$ converges to $x \in \mathbb{R}^+$. Suppose that $(y_n)_n$ is bounded. Prove that $$\limsup_{n \to +\infty} x_n \cdot y_n = x \cdot \limsup_{n \to +\infty} y_n$$  I know that $x=\limsup_{n \to +\infty} x_n$, so it basically comes down to proving $\limsup_{n \to +\infty} x_n \cdot y_n = \limsup_{n \to +\infty} x_n \cdot \limsup_{n \to +\infty} y_n$, but that's where I'm stuck...

Note: $x_n$ is a sequence which is not necessarily convergent.    The following was my attempt. Since $\lim_{n\to \infty}a_n=a$ then $\limsup_{n\to \infty}a_n=a$ . Also $\sup(a_nx_n)=\sup(a_n)\sup(x_n)$. Therefore, $\limsup_{n\to \infty}a_nx_n=\limsup_{n\to \infty}a_n\limsup_{n\to \infty}x_n=a\limsup_{n\to \infty}x_n$.    I am not sure if this is correct. So could someone please show me how it is done. Thanks


I am trying to reset ubuntu 19.10 to factory default values. I tried  but I think it doesn't work for ubuntu 19.10

Problem I Faced  I installed something that crashed my Wifi drivers that I compiled earlier. Un-installing the same package doesn't helped. Finally, I re-compiled my wifi drivers and things are good.  My Question But, is there anything like System Restore or System Rollback in Ubuntu/LinuxMint?  Is there anything that can undo an apt-get install package command?


Incident which happened a week ago:      Me to Kate: "Where are you going"?   Kate: "I'm going to the cinema".   Now today I happen to tell this story to Jim and I say,      "I met Kate a week ago."   Jim: What did she say?   Me: "Kate said that she 'is' going to the cinema".    My question is, is the usage of 'is' grammatically correct? Here, at the time of reporting after a week I don't know if she's still going to the cinema or not and even then I use 'is' will this be grammatically correct?

Grammar rules say that when converting a sentence from direct speech to indirect, the reported speech is converted to past tense if the first part of the sentence (reporting verb) is in the past tense.  Direct speech: John said, “I will give you a pen”. Indirect Speech: John said that he would give me a pen. S1: I wanted to let you know that he has sent you an email S2: I wanted to let you know that he had sent you an email  I have seen people write S1 even though it doesn't follow the grammar rule regarding change of tense in the reported speech. Which of these ones correct and incorrect? Why correct and why wrong?


When I am developing a predictive statistical model, why do I need to ensure the error is normally distributed? (I have a very small statistical background, so I apologize in advance if this is a very, very basic question).

In linear regression, each predicted value is assumed to have been picked from a normal distribution of possible values. See below.  But why is each predicted value assumed to have come from a normal distribution? How does linear regression use this assumption? What if possible values are not normally distributed?


I installed Ubuntu via DVD onto a Windows 10 laptop.  During boot, Ubuntu is the default option, and Windows 10 is a menu option.  How do I make Windows 10 the default boot option please?

In Ubuntu 12.04 (or above), how do I set the GRUB time and the default OS (that I see at boot time) as I'm dual-booting Windows (7/8) and Ubuntu (12.04 or above)?


We had a situation last session where I (sorcerer/monk) ended my turn mid air after striking a flying monster trying to flee. It was already 100 feet high so I used a quickened Thunder Step to teleport 90 feet up on the wall and step of the wind to jump from it and strike the monster with two melee attacks. It wasn't enough to finish it and I was left mid air. I thought that I would immediately fall down and be okay since it's a forced movements and thus does not trigger an Opportunity Attack and thanks to the Slow Fall feat I wouldn't take too much damages. But The DM ruled it as the monster getting to hit me before I fall since his turn was next so I was knocked unconscious and died of the fall (no Slow Fall when you're unconscious). I'm not mad at the DM for making this choice, I knew it was a reckless action when I took it, but it got me thinking when should a character start falling when they ends their turn in the air.

Situation:  Alice the Aarakokra sees Bob the Battlemaster coming. She ascends to 605', just out of the 600' range of Bob's longbow.  Bob (Str 14) performs a running high jump 5' into the air and successfully hits Alice with his longbow, despite firing at disadvantage for long range. He spends one of his maneuver dice to perform the Trip Attack maneuver, and succeeds on the contested roll to knock Alice prone.  Alice is now flying and prone, so she falls. Falling does 1d6 bludgeoning damage per 10' fallen, to a maximum of 20d6.  Questions:   When does Alice start falling? It is on Bob's turn as soon as she's knocked prone, or some time else such as the beginning of her own next turn? When does Alice hit the ground? On Bob's turn as soon as she's knocked prone, or some time else?   These answers determine whether anyone can save Alice from her 20d6 of certain doom.   Is a reaction (e.g. casting Feather Fall) on Bob's turn the only hope? Can Alice's ally Charlie swoop in on his subsequent turn within the same round to catch her? Can Alice spend half her movement on her next turn to "stand from prone" and pull out of her involuntary dive? If Alice had expected to be shot down, could she have spent an action to be Ready to "stand from prone" while moving through Bob's airspace?


I have raster image that projected by WGS1984 UTM Zone 37N. But my shapefile was Adindan UTM Zone 37N. Due to this, it doesn't overlay the same. I tried to define projection for the raster image to Adindan UTM zone 37N, But not match. So, how can I display the raster image in Adindan UTM Zone 37N without change WGS1984 UTM Zone 37N?

I put 4 different layers into my ArcMap document, but only one of them will show up on the map! I should be seeing the other 3 layers as well. When I do a Zoom to layer, I can see one layer, but I cannot figure out how to make the other 3 show up at once on top of each other.  Before I opened ArcMap, I used ArcCatalog where I right-clicked 3/4 of the shapefiles and  clicked Properties → Coordinate system → Import and then clicked on my Trees layer, which has the coordinate system I want the other 3 to have. But when I opened ArcMap the 4 layers did not overlap, nor could I move them above or below each other.


I'm taking data from an external XML file, so I cannot make changes. Also I need all special characters.  This is XML  <item> <name>Lucy</name> <embed><iframe src='http://website.com style='something:somehow'></iframe></embed> </item>   This is sql table  $sql = "CREATE TABLE IF NOT EXISTS `models`(     `model_id` INT NOT NULL AUTO_INCREMENT PRIMARY KEY,     `model_username` VARCHAR(250) NOT NULL,     `model_embed` TEXT NOT NULL )";   XML into SQL  foreach ($items as $item) {        $name=$item->name;        $iframe=$item->embed;  $ins = " INSERT INTO `models` (`model_username`, `model_embed`)          VALUES ('$name', '$iframe') }   And I get this error     1064 : You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ' style='something:somehow' at line 9

If user input is inserted without modification into an SQL query, then the application becomes vulnerable to , like in the following example:  $unsafe_variable = $_POST['user_input'];   mysql_query("INSERT INTO `table` (`column`) VALUES ('$unsafe_variable')");   That's because the user can input something like value'); DROP TABLE table;--, and the query becomes:  INSERT INTO `table` (`column`) VALUES('value'); DROP TABLE table;--')   What can be done to prevent this from happening?


When i select the plate (see picture) the option for particles remains blank. Any ideas? noob with only 10 hours in blender.

I have added a sphere and I was able to add material and give it a color. Now when I add a second sphere (separate object), the material panel is just blank.


I've set up a small java project, in which I want to display a JFrame with a given icon. When running locally in Eclipse everything works just fine, using: ImageIcon img = new ImageIcon("resources/twitch.png"); frame.setIconImage(img.getImage());  However, after exporting the project as a runnable jar, the icon doesn't apply and instead it uses the standard java icon for the JFrame. How can I fix this? After searching for similar problems, I've found that the most frequent solution involves using: URL resource = frame.getClass().getResource("/twitch.png");  With or without the leading /. Unfortunately, with this approach I keep getting a Nullpointer (Illegal Argument Exceptions stating that the input cannot be null). I've tried various ways copying the image somewhere else and changing the path string or trying an absolute path to my harddrive, but always the same result, NullPointerException. Another person told me that maybe I've done something wrong when exporting the project or the packet structure of my project is messed up but he couldn't help me much either. Here is the structure:  Any help is much appreciated.

When running a Java app from eclipse my ImageIcon shows up just fine.  But after creating a jar the path to the image obviously gets screwed up.  Is there a way to extract an image from the jar at runtime so I can then open it up?  Or, is there a better way to do this?  I'd like to distribute a single jar file if possible.


I understand according to the rules for flying that  If a flying creature is knocked prone, has its speed reduced to 0, or is otherwise deprived of the ability to move, the creature falls, unless it has the ability to hover or it is being held aloft by magic, such as the fly spell.  However, my question is when the flying creature is given the prone status when does it begin to fall, and how far does it fall? an example is as follows: A 3rd level Battlemaster Fighter confirms a hit on a Harpy flying 30ft above the ground. The Battlemaster then expends a superiority die to use their trip attack, the harpy then fails its strength save and is knocked prone.


I tried to solve this problem with python 2.7. I just began programming so I hoped that one of you amazing people could help me out!   this is what i currently have:  my_list = [2,3,4,5,6,7,8,9,10,11,]   for a in range(0, 39916800):      if (a % my_list == 0):         print("a")   THE ANSWER =  a = 2*3*4*5*6*7*8*9*10*11  a = a-1  for a in range (0,a): if a % 2 == 0:     if a % 3 ==0:         if a % 4 ==0:             if a % 5 ==0:                 if a % 6 ==0:                     if a % 7 ==0:                         if a % 8 ==0:                             if a % 9 ==0:                                 if a % 10 ==0:                                     if a % 11 ==0:                                         print a                                         if a > 1:                                             break

How do you calculate the least common multiple of multiple numbers?  So far I've only been able to calculate it between two numbers. But have no idea how to expand it to calculate 3 or more numbers.  So far this is how I did it    LCM = num1 * num2 /  gcd ( num1 , num2 )   With gcd is the function to calculate the greatest common divisor for the numbers. Using euclidean algorithm  But I can't figure out how to calculate it for 3 or more numbers.


When we solve for inner product of $\rvert a \rangle \cdot \rvert b \rangle$ we solve for $\langle a \rvert b \rangle$ where $\langle a \rvert$ is complex conjugate of $\rvert a \rangle$. However this confuses me because in linear algebra, $u \cdot v$ is $uv^*$. The latter vector is conjugated. Why does braket notation conjugate prior vector and linear algebra conjugate latter vector?

I am trying to reconcile the definition of Inner Product Spaces that I encountered in Mathematics with the one I recently came across in Physics.  In particular, if $(,)$ denotes an inner product in the vector space $V$ over $F$:    $(u + v, w) = (u, w) + (v, w) \text{ for all } u, v, w \in V$, $(\alpha v, w) = \alpha(v, w) \text{ for all } v, w \in V$ and $\alpha \in F$, $(v, w) = (w, v)^* \text{ for all } v, w \in V$, (* denotes complex conjugation)   were some of the properties listed in my mathematics course.    In physics, however, the inner product was said to be linear in the second argument and $(v,\sum(\lambda_i w_i)) = \sum(\lambda_i (v,w_i))$ where $v$ and $w_i$ are kets in Hilbert space and $\lambda_i$ are complex numbers.    To me, these properties of an Inner Product are not compatible.  If the first definition of inner product is correct, then I think $(v,\sum(\lambda_i w_i)) = \sum((\lambda_i)^* (v,w_i))$ where $^*$ denotes complex conjugation.


We have all heard the typical “Put a jacket on youre going to catch a cold.” Usually stated by an older person typically a grandmother. Excuse the stereotype. Is there any evidence that colder weather makes one more prone to catching the flu or cold or is this simply a myth and misconception.

The word flu derives from the Italian phrase "influenza de freddo" meaning "influence of the cold".  Indeed it is that time of the year when my colleagues seem to have the flu/cold more often than not. I remember during university, winter lectures would be riddled with people coughing and sneezing - the so called "freshers flu"  Questions   Is there statistical evidence for this claim? If so, what are the causes/factors involved?   asks why our noses get runnier during cold whether, is this related?


I got this question in a class and can't figure out the answer:  $i^2 = (-i)^2 = -1$  $(e^{πi(2n + 1/2)})^2 = (e^{πi(2m - 1/2)})^2$  $e^{πi(4n + 1)} = e^{πi(4m - 1)}$  $\ln(e^{πi(4n + 1)}) = \ln(e^{πi(4m - 1)})$  $πi(4n + 1) = πi(4m - 1)$  $m = n + 1/2$  Which isn't possible for m and n both being integers. But I can't figure out what exactly is wrong with what is written here.

Using the relation $\ e^{ix} = \cos(x) + i\sin(x)$ and substituting for $\ x = \pi$, we have the well-known Euler identity, $ e^{i\pi} = -1$. Substitute also for $ x = -\pi $, we have $ e^{-i\pi} = -1$. So we can say $ e^{i\pi} = e^{-i\pi}$ and taking $\ln$ on both sides, $i\pi=-i\pi$. There is clearly something wrong here. Can some help me to figure out what's wrong?  EDIT :  I actually had a confusing output from my calculator while trying to solve the problem :


I want to install SharePoint on a Windows 10 Pro PC. How can I do this, and is there any extra software required?

I know This is not related to development, please accept me this time. I'm looking to upgrade windows 8.1 to windows 10 .   Can I able to install SharePoint 2013 on windows 10?  I couldn't find any articles about SharePoint support on win 10.  Thanks


Question really says it all. How to add partitions during install of Ubuntu? Is there a limit to the partitions that you can create, or is it more space-efficient to use one partition? Also, is it possible to 'merge' two partitions into one?

I'd like to see the full How-To on how to use manual partitioning during Ubuntu installation. The existing guides (at least those I found here) cover only automatic part and leave untouched the manual part (or extremely short and contain no pictures).  I'd like to cover such situations:     If your disk contains other systems:


When I parameterize the date in the code as :  str_last_log_date="2017-07-24" last_log_date=$(date -d '${str_last_log_date}' +%s) threshold_days_ago=$(date -d 'now - 2 days' +%s) echo "last_log_date ${last_log_date}  thres_days_ago ${threshold_days_ago}"   Gives the error :     date: invalid date ‘${str_last_log_date}’    last_log_date thres_days_ago 1500969455   But if I don't parameterize the date and pass directly, it gives the correct result :   last_log_date=$(date -d '2017-07-24' +%s) threshold_days_ago=$(date -d 'now - 2 days' +%s) echo "last_log_date ${last_log_date}  thres_days_ago ${threshold_days_ago}"      last_log_date 1500854400  thres_days_ago 1500969511   Any tips?

I used to use '' and "" (single and double-quotes) interchangeably on the command line, but I recently noticed that '$HOME/some/dir' is not expanded, while "$HOME/some/dir" is. I searched around a little bit and found that "" allows some protection of special characters, while '' allows full protection. So what other characters are protected by '' and not ""?  EDIT: What are practical situations in which these differences might be significant?


My laptop has a 1TB HDD. I'd like to install Ubuntu on it. Is it possible to do this, except make it so that Windows and Ubuntu share the entire drive, without formatting it? Also, if this is possible, I'd like to have all of Ubuntu's system files tucked away in a single directory on the drive, and have custom locations for some of the /home directories.

I have a new laptop with SSD + HDD. I already managed to set up a dual boot with Windows 10 preinstalled and Ubuntu 17.10.  Ubuntu root, home and swap directories are all on the SSD. In addition I took 500GB from the HDD and created a partition for my data (I called it /mnt).   Now I want to make the operating system store music, downloads, documents, pictures and videos on the HDD data partition, while maintaining /home on the SSD.   I know it has to do with fstab, so I found the file and a way to edit it, but what am I supposed to do now? The general information is not clear enough for me.   Here is my fstab:   # /etc/fstab: static file system information. # # Use 'blkid' to print the universally unique identifier for a # device; this may be used with UUID= as a more robust way to name devices # that works even if disks are added and removed. See fstab(5). # #                 # / was on /dev/sdb6 during installation UUID=cbdf87b9-ddf0-4242-a6b3-12ea1f13c653 /               ext4    errors=remount-ro 0       1 # /boot/efi was on /dev/sdb1 during installation UUID=7E53-EFDB  /boot/efi       vfat    umask=0077      0       1 # /home was on /dev/sdb7 during installation UUID=a78d2329-659f-4d6e-a7e3-c54f08dc5bdb /home           ext4    defaults        0       2 # /mnt was on /dev/sda2 during installation UUID=193e6f14-a677-4f3e-9373-06f6d12c12f0 /mnt            ext4    defaults        0       2 # swap was on /dev/sdb5 during installation UUID=e8fe7608-591e-40b2-ab28-603b058c87f9 none            swap    sw              0       0  Can someone guide me step by step?


When new Lead is created I would like to post on chatter group with clickable first and last name of lead, which would redirect user to record page.  Here is what i tried:   I tried to mention @[Lead].Id but it crashes Process Builder. I tried formula field HYPERLINK("/"+Id, 'FirstName') But it returns me this:     So is there any other solution for this? Greetings, Bartek

I've created a workflow using the process builder and added a Chatter Post as an action. How Can I add a link to that post, a link which people can click and go to a SF record?


I'm getting the error when I run sudo apt upgrade: Citing for cache lock: Could not get lock /var/lib/dpkg/lock-frontend. It is held by process 12111 (synaptic)...4s  So, I tried sudo lsof /var/lib/dpkg/lock-frontend, and got this: lsof: WARNING: can't stat() fuse.gvfsd-fuse file system /run/user/1000/gvfs       Output information may be incomplete. lsof: WARNING: can't stat() fuse file system /run/user/1000/doc       Output information may be incomplete. COMMAND    PID USER   FD   TYPE DEVICE SIZE/OFF     NODE NAME synaptic 12111 root   11uW  REG    8,5        0 49152209 /var/lib/dpkg/lock-frontend  I'm not sure what is happening here. All I ever did was to remove a broken package. You can check my  for that. But how do I solve this cache lock problem?

I get this error when trying to use apt-get:  E: Could not get lock /var/lib/dpkg/lock - open (11 Resource temporarily unavailable) E: Unable to lock the administration directory (/var/lib/dpkg/) is another process using it?     How can I fix this?


I'm on Bedrock Edition (Windows 10, same as PE) and was wondering if there was any way to go above max on enchanting. For example, if I type /enchant ExamplePlayerName sharpness 10 it would just say the enchantment max was 5. Is there any way I can bypass this?

In Minecraft, the NBT (Named Binary Tag) format is used to store data of our Minecraft worlds, including block, entity, and item properties. In the Java Edition of Minecraft, you can modify this data by including the data in the command, like so: /give @s diamond_sword{Enchantments:[{id:"minecraft:knockback",lvl:10s}]}  In the Bedrock Edition, on the other hand, NBT is inaccessible from commands. In order to modify NBT, we need to use an external editor. What are some useful item properties that I can modify with an NBT editor, and how can I do so?  Related:


Please help cover bold lines dont know why email.plainTextBody.length() >=255 is not covering if(email.plainTextBody!=null && email.plainTextBody.length() >=255) { bodyString= email.plainTextBody.split('\n', 0); body = bodyString[0]; comment = bodyString[1];  uName = bodyString[2]; uString = uName.replaceAll(regex, ''); uniqueContractNo = uString.replaceAll( '\s+', ''); global class frEmailServiceClass implements Messaging.InboundEmailHandler {     global Messaging.InboundEmailResult handleInboundEmail(Messaging.InboundEmail email, Messaging.InboundEnvelope envelope) {     string body='', fromEmailId='';         list<string> approvalString = new list<string>{'APPROVE', 'APPROVED', 'YES'};         list<string> rejectionString = new list<string>{'REJECT', 'REJECTED', 'NO'};         string[] bodyString;         string comment;         string uniqueContractNo;         string subj =email.subject;         string regex = '[a-zA-Z]{1,}|\\:';         string cString = subj.replaceAll(regex, '');         string cName = cString.replaceAll( '\\s+', '');         string uName;         string uString;         try{         **if(email.plainTextBody!=null && email.plainTextBody.length() >=255) {           bodyString= email.plainTextBody.split('\n', 0);         body = bodyString[0]; comment = bodyString[1];  uName = bodyString[2];         uString = uName.replaceAll(regex, ''); uniqueContractNo = uString.replaceAll( '\\s+', '');**                                                                                }                 fromEmailId = email.fromAddress;            Contract_management__c   contractQuery = new Contract_management__c();             if(cName!=null){             system.debug(cName);         contractQuery = [select id,name,Status__c,Comments__c,Unique_Contract_Number__c,owner.email,Legal_Person_Email__c,Send_Email_To_Legal__c from Contract_management__c where name=:cName and Legal_Person_Email__c=:fromEmailId limit 1];             }                  **for(string a:approvalString){                     if(body.contains(a) && contractQuery!=null){ contractQuery.Status__c= 'Legal Approved';             contractQuery.Send_Email_To_Legal__c=false;  contractQuery.Comments__c=comment;             contractQuery.Unique_Contract_Number__c=uniqueContractNo;             }                            }                  for(string r:rejectionString){         if(body.contains(r) && contractQuery!=null){ contractQuery.Status__c= 'Legal Rejected';             contractQuery.Send_Email_To_Legal__c=false; contractQuery.Comments__c=comment;               contractQuery.Unique_Contract_Number__c=uniqueContractNo;             }                            }                           update contractQuery;**         }         catch(Exception ex){             System.debug('Line No: '+ex.getLineNumber()+' Message: '+ex.getMessage()+' Cause: '+ex.getCause());         }         Messaging.InboundEmailResult result = new Messaging.InboundEmailresult();             return result;     } }  Test class method @isTest      static void testContractEmailServiceMethod(){         string cid;         Contract_management__c queryC = [select id,name,Legal_Person_Email__c,Customer_Account__c,Contact__c,Contract_Type__c,Contract_Start_Date__c,Contract_End_Date__c,Status__c from Contract_management__c limit 1 ];         cid=queryC.name;     list<string> approvalString = new list<string>();     Messaging.InboundEmail email = new Messaging.InboundEmail() ;     Messaging.InboundEnvelope envelope = new Messaging.InboundEnvelope();          FREmailServiceClass contractClassObj = new FREmailServiceClass();          email.plainTextBody = 'APPROVED\n ok\n 0090';     email.fromAddress ='test@u.com';     email.subject = cid;               contractClassObj.handleInboundEmail(email, envelope); }

This is a canonical question and answer developed by the community to help address common questions. If you've been directed here, or your question has been closed as a duplicate, please look through the resources here and use them to shape more specific questions. To browse all canonical questions and answers, including more unit test resources, navigate to the  tag.  This canonical question is intended to address several classes of common questions by providing a quick summary and links to comprehensive resources:   How is code coverage obtained and calculated? How do I increase my coverage?  Why can't I cover these lines? Why isn't the body of my loop or conditional statement covered?


I have a new computer with no disk drive and a Windows 10 (NTFS) partition, and I wanted to install Ubuntu 18.04 in dual boot configuration from a USB boot drive (exactly as I have done before for 16.04 on a Windows 7 (FAT32) machine). I followed several instructions (e.g. ) which recommend using Rufus 3.8, which does the job if I keep the default file system (FAT32), however when the installation comes to the screen for choosing Installation type there are no options. This appears to be because the installer cannot recognize the existing Windows NTFS partition.   On the other hand, if I specify an NTFS file system in Rufus, then it creates two partitions on the USB drive (one FAT and one NTFS) and gets stuck in grub without progressing to the installation options, regardless of which USB partition I prioritize in the boot menu. I tried some tips for getting out of grub, but "exit" is all that works, and the system resorts to Windows.   I have tried other USB formatting tools, but with less luck. I have disabled Secure Boot in the menu, and I have disabled hibernation completely. The only hint I have is snapping some lines that come up, for about 0.5 sec., just before the grub prompt takes over.  These seem to be talking about detecting and then disconnecting an existing NTFS system. It seems that what I am trying to do should be straightforward, but I am beginning to doubt whether it is possible at all.  Perhaps the Rufus developer, Akeo, could respond, as he mentioned that he had managed this about 18 months ago: .

I have DELL Precision, with 512GB SSD. I did shrink the only Drive C,  and made 125 GB of unallocated space to install Ubuntu on it.  restarting the system choosing boot, install Ubuntu, the installation process does not recognize any hard disk except the Flash memory that contains ubuntu bootable.  the information from Windows 10 side:  Dell Precision 3520 windows 10 pro Intel Core i7-7820HQ BIOS mode UEFI from the device manager; Storage Controllers:         Intel chipset SATA/PCIe RST premium controller         microsoft spaces storage controller         microsoft VHD loopback controller Disk 0: (Basic)        SSDPEKK NVMe INTEL 512GB               Partition Style GPT Rapid Storage Technology:        Controller 1, Port 0        Port Location Internal        Type PCIe solid-state drive        System Disk: yes        Controller Type: NVMe BIOS options on power up:         System Configuration/SATA Operation = RAID on (Intel RST)   I've read that the Ubuntu kernel is compatible with RST and should recognize the SSD, Also the Disk 0 is shown as basic which I think means hardware RAID.  What should do in this case to have a dual boot installation of Ubuntu


The general syntax of slicing  [start:stop:step]   It will be evaluate start:stop-1 and step(default 1)  >>> l = [x for x in range(5)] >>> l[0:6] [0, 1, 2, 3, 4] >>> l[1:-1] #case second [1, 2, 3] >>> l[1:-5] #case third []   Why in the case third it returns an empty list and also i don't understand in case second how step can be incremented by 1 if stop value in -ve.

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


Why do so many formula use Euler's number? What's the role of the "e" about in many formula?  I know that it's 2.7xxxx value and something good for compound interest. Please tell me how I think it as, when faced with in some formula.  $ex \begin{eqnarray}\sigma(z) \equiv\frac{1}{1+e^{-z}}\tag{3}\end{eqnarray}$

Potentially related-questions, shown before posting, didn't have anything like this, so I apologize in advance if this is a duplicate.    I know there are many ways of calculating (or should I say "ending up at") the constant e.  How would you explain e concisely?  It's a rather beautiful number, but when friends have asked me "what is e?" I'm usually at a loss for words -- I always figured the math explains it, but I would really like to know how others conceptualize it, especially in common-language (say, "English").     related but not the same:


Example: You have a costumer you have been working with who purchases something then your coworker later says they purchased because of something they did (like discrediting you). Or another example would be, they are asked a simple question and then make it seem that the person who asked the question was freaking out and that they calmed them down even though the person was not freaking out at all? I thought self righteous may be right but now I am not sure.

Is there an adjective or adverb depicting self-promotion (or promotion of a group one belongs to)?  I am thinking of something that has a somewhat negative connotation, in the spirit of phrases   patting yourself on the back shameless self-plug


When I want to watch a question the content disappear.          App Version: 1.0.85 Device Manufacturer: samsung Device Model: SM-G920F OS Version: 6.0.1 (G920FXXU3DPCM)

Since the last update (v1.0.85), I am getting all the question pages blank on the Android app. For those who are confused with the image, I'm using RtL (Right-to-Left) layout.        If I scroll down (quite a bit) I can see the question. But even then I cannot see the question title, the related comments or answers.         App Version: 1.0.85 Device Manufacturer: LGE Device Model: LG-D620   OS Version: 5.0.2 (152541901f156)


This will be a very dumb question to the gurus I'm guessing but here goes. I am trying to keep track of the number of threads on my system and I need to add timestamp somewhere with each output. Here is my current command to check number of threads : watch -n1 'ps -eLo pid,cmd,nlwp | wc -l >> test.txt'  I would like the timestamp to be added on each line in test.txt as the number of threads gets written How do I get the output to look like 2020-12-14 07:08:10 5431 (where 5431 is the number of threads) ?

When I ping I have this display:  > ping -i 4 www.google.fr  64 bytes from wi-in-f94.1e100.net (173.194.67.94): icmp_seq=503 ttl=46 time=45.5 ms ....... ....... 64 bytes from wi-in-f94.1e100.net (173.194.67.94): icmp_seq=508 ttl=46 time=44.9 ms 64 bytes from wi-in-f94.1e100.net (173.194.67.94): icmp_seq=509 ttl=46 time=45.1 ms   I'd like to have the time of the ping before.   Something like:  > (right functions) + ping -i 7 www.google.fr  mardi 15 mai 2012, 10:29:06 (UTC+0200) - 64 bytes from wi-in-f94.1e100.net (173.194.67.94): icmp_seq=503 ttl=46 time=45.5 ms ....... ....... mardi 15 mai 2012, 10:29:13 (UTC+0200) - 64 bytes from wi-in-f94.1e100.net (173.194.67.94): icmp_seq=508 ttl=46 time=44.9 ms mardi 15 mai 2012, 10:29:20 (UTC+0200) - 64 bytes from wi-in-f94.1e100.net (173.194.67.94): icmp_seq=509 ttl=46 time=45.1 ms   How would you do this in a command line (if it's possible)?


I've read around that installing an Ubuntu desktop on top of an Ubuntu Server provides security holes and performance issues. But I can't find anywhere as to describe what security holes would develop from doing this? I am thinking of installing a light weight desktop such as Xubuntu. Can anyone explain further? What type of security holes? Do I need to be concerned?  All help is much appreciated!

I remember reading that servers do not have a GUI because X11 is a security risk. Why?


I have tried with below code but getting an exception as shown below - public class TestCaseFile {     public static void main(String [] args) throws IOException {         String imgOriginal = "C:\\Users\\nn252j\\Desktop\\personal\\photos\\Output\\minionFloppedImage.jpg";         String imgToCompareWithOriginal = "C:\\Users\\nn252j\\Desktop\\personal\\photos\\Output\\minionFloppedImage.jpg";         String imgOutputDifferences = "new_screenshot_with_changes.jpg";          ImageComparison imageComparison = new ImageComparison(10,10,0.05);          if(imageComparison.fuzzyEqual(imgOriginal,imgToCompareWithOriginal,imgOutputDifferences))             System.out.println("Images are fuzzy-equal.");         else             System.out.println("Images are not fuzzy-equal.");     } }  Exception Details Exception in thread "main" java.lang.NoClassDefFoundError: net/coobird/thumbnailator/Thumbnails at org.frontendtest.components.ImageComparison.adaptImageSize(ImageComparison.java:105) at org.frontendtest.components.ImageComparison.fuzzyEqual(ImageComparison.java:36) at org.frontendtest.components.ImageComparison.fuzzyEqual(ImageComparison.java:23) at TestCaseFile.main(TestCaseFile.java:12)

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


What differences between two below commands in CentOS7?  $ type cd cd is a shell builtin   and  $ which  cd cd is a shell builtin cd is /usr/bin/cd cd is /bin/cd   The cd is a shell builtin command, but why which command show another path for cd ?  Is the cd command both internal command and external command ?

As referenced in , POSIX systems have an external binary cd in addition to the shell builtin. On OS X 10.8 it's /usr/bin/cd. You can't use it like the builtin cd since it exits immediately after changing its own working directory. What purpose does it serve?


Given that $$\sum_{n=1}^\infty \frac{1}{n^4} = \frac{\pi^4}{90}$$ find $$\sum_{n=1}^\infty \frac{(-1)^n}{n^4}$$ The answer should be $\frac{-7\pi^4}{720}$.

Is it possible to use the fact that $\sum_{n=1}^\infty \frac{1}{n^4} = \frac{\pi^4}{90}$ to compute $\sum_{n=1}^\infty \frac{(-1)^n}{n^4}$?


If a non-axis-aligned ellipsoid is defined by $$\tag{1} \bf x^T A x=1$$ where $\bf x$ $=[x, y, z]^T$, $\bf A$ $=\begin{bmatrix}a_{xx}&a_{xy}&a_{xz}\\a_{yx}&a_{yy}&a_{yz}\\a_{zx}&a_{zy}&a_{zz} \end{bmatrix}$, and $a_{ij}=a_{ji}$,  then Eqn(1) is the following when expanded: $$\tag{2} a_{xx}x^2+a_{yy}y^2+a_{zz}z^2+2a_{xy}xy+2a_{xz}xz+2a_{yz}yz=1$$  at $z=0$ the coordinates of the ellipsoid is: $$\tag{3} a_{xx}x^2+a_{yy}y^2+2a_{xy}xy=1$$  which I think is also an equation of an ellipse since its the intersection of the ellipsoid and the x-y-plane.  Equation 3 is in implicit form.  How can its parametric equations be found?

I want to find the parametric equation of the ellipse in 3d space which is formed by the intersection of a known ellipsoid and a known plane. The ellipsoid has the Cartesian equation: $(x/a)^2+(y/b)^2+(z/a)^2=1$.  While the plane has the equation: $mx+ny+kz=0$. I have substituted one equation in the other but what I get is an elliptical cylinder since I had eliminated the $z$-components. How can I get the exact equation of the ellipse of intersection in parametric form?


Problem: $$\lim_{n\to +\infty} n\left(\sum_{k=1}^{n}\frac{1}{n^2+k^2}\right)=$$ Source: AP Calculus BC  This looks like the definition of a definite integral to me, so I compared it to that equation. $$\int_a^b\!f(x)\,\mathrm{d}x=\lim_{n\to\infty}\sum_{k=1}^{n}f(x_i)\Delta x$$ where $\Delta x=\frac{b-a}{n}$.  However, I am now stuck because $\Delta x$ has $n$ in the denominator whereas the problem has $n$ in the numerator.  Is my approach incorrect or did I apply the definition incorrectly? How do I find the function that is being integrated and $\Delta x$?  Thank you in advance!

How do you calculate that: $$\lim_{n \to \infty} \sum_{k=1}^{n} \frac {n}{n^2+k^2} = \frac{\pi}{4}$$ ? In general I would look for a formula for the expression inside the sigma, and then calculate. But I have no idea what kind of formula there is for this expression. Hint?


I have some list with objects looks like:  oldList=[a,b,c,d,e,f,g,h,i,j,...]   what I need is to create a new list with nested list items which will look like this:  newList=[[a,b,c,d],[d,e,f,g],[g,h,i,j]...]   or simply spoken - last element from previous nested is first element in next new nested list.

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


what exactly I am doing wrong here? in .h namespace test1 {     template <typename ...T>     void test1_test1(T & ...t); };  in . cpp namespace test1{     template <typename ...T>     void test1_test1(T & ...t) {         std::cout << "this is test1_test1" << std::endl;     } }  also in classes In .h class testing2 { public:     template <typename ...T>     void test1_test1(T & ...t); };  in .cpp template <typename ...T> void test1_test1(T & ...t) {     std::cout << "this is test1_test1" << std::endl; }  error : Undefined symbols for architecture x86_64:   "void test1::test1_test1<>()", referenced from:       _main in main.cpp.o ld: symbol(s) not found for architecture x86_64 clang: error: linker command failed with exit code 1 (use -v to see invocation) make[2]: *** [testing_template] Error 1 make[1]: *** [CMakeFiles/testing_template.dir/all] Error 2 make: *** [all] Error 2  also in gcc error as well how to define Variadic functions in classes ? many thanks

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


My wife has an Optimus LG. Every photo she takes automatically syncs with Dropbox and Facebook. I have looked but I can't see a way to stop this.  How can I stop this behavior?

How do I configure Dropbox on my mobile - Galaxy S III so that it does not automatically upload every photo and video I take?


A group of pirates with 17 members steal a bag of golden coins. When they share their loot evenly, it left with 3 coins. When they argue who should get the remaining of the coins, one of them is killed. Then the coins where shared again evenly. But now it left with 10 remaining coins.  Another riot happened and one of them is killed again. This result in dividing the coins again and it turns out all of the pirates have the same amount of coins.  Determine the amount of gold coins in the bag!

I was reading an example from my book, and I need further clarification because I don't understand some things. I'm just going to include the $f_1$ part in full detail because $f_2$ and $f_3$ are identical.   Consider the following problem.  Once upon a time, a band of seven pirates seized a treasure chest containing some gold coins (all of equal value). They agreed to divide the coins equally among the group, but there were two coins left over. One of the pirates took it upon himself to throw the extra coins overboard to solve the dilemma. Another pirate immediately dived overboard after the sinking coins and was never heard from again. After a few minutes, the six remaining pirates redivided the coins and found that there were three coins left. This time a fight ensured and one pirate was killed. Finally, the five surviving pirates were able to split the treasure evenly. What was the least possible number of coins in the treasure chest to begin with?   If x represents the original number of coins, then the first division can be represented by the congruence   $x \equiv 2 $ (mod $7)$ [I understand this part because originally we had 7 pirates and 2 left over coins]  The second and third division give the congruences  $x - 2 \equiv 3$ (mod $6$) and $x-2 \equiv 0 $ (mod $5$).  [The second division is the 2 coins that were thrown overboard, the pirate jumping into the ocean is the new mod, and there are 3 coins leftover. The third division is the original 2 coins thrown overboard, the 5 surviving pirates, and nothing is left over].  So the system of congruences is $x \equiv 2$ (mod 7), $x \equiv 5$ (mod 6), and $x \equiv 2$ (mod 5)  We solve the system by letting $x= 2f_1+5f_2+2f_3$  where $f_1,f_2$, and $f_3$ (to be determined soon ) satisfy   $f_1 \equiv 1$ (mod 7) $f_2 \equiv 0$ (mod 7) $f_3 \equiv 0$ (mod 7)  $f_1 \equiv 0$ (mod 6) $f_2 \equiv 1$ (mod 6) $f_3 \equiv 0$ (mod 6)  $f_1 \equiv 0$ (mod 5) $f_2 \equiv 0$ (mod 5) $f_3 \equiv 1$ (mod 5)  [Where are they getting this from?]  To compute $f_1$ we set $f_1 = 6 \times 5 \times b_1$ where $b_1$ satisfies the single congruence $ 6 \times 5 \times b_1 \equiv 1$ (mod 7)  [Ok. That 6 and 5 comes from mod 6 and mod 5, but why is there a 1 at the end of the equation?]  Note that $f_1$ is necessarily divisible by 6 and by 5 and is congruent to 1 modulo 7. Thus $f_1 \equiv 1$ (mod 7), $f_1 \equiv 0$ (mod 6), and $f_1 \equiv 0$ (mod 5)  To solve the congruence, reduce $ 6 \times 5$ modulo 7 to get $2b_1 \equiv 1$ (mod 7) [ $ 6 \times 5 = 30 $, so if I divide 30 by 7, I would get a remainder of 2 because $ 7 \times 4 = 28$ and $ 30-28=2$.   Note that $b_1 = 4$ is a solution. [WAIT! Where did that 4 come from? Now I'm really confused. What are the steps?]


i want to send email verfication to the new user. i am using firebase authentication. I have tried in this way, but it's giving me problem. it's not working  @Override public void onActivityResult(int requestCode, int resultCode, Intent data) {     super.onActivityResult(requestCode, resultCode, data);      if (requestCode == RC_SIGN_IN) {         IdpResponse response = IdpResponse.fromResultIntent(data);         System.out.println("Respuesta: "+response);                   if (resultCode == RESULT_OK) {                     // Successfully signed in                       if (response.isNewUser()){                         System.out.println("Eres nuevo");                         auth.sendEmailVerification();   Here is the error     Attempt to invoke virtual method 'com.google.android.gms.tasks.Task com.google.firebase.auth.FirebaseUser.sendEmailVerification()' on a null object reference

What are Null Pointer Exceptions (java.lang.NullPointerException) and what causes them?  What methods/tools can be used to determine the cause so that you stop the exception from causing the program to terminate prematurely?


If I book a flight (Emirates) from New Delhi to Fort Lauderdale via Dubai, i.e halt at Dubai for a duration of 2 hours or 8 hours, then will there be any problem? Do I need a transit visa?

I am a Pakistani national and need to transit through Dubai International Airport (DXB).  I am not planning to leave the airport and both of my flights (arrival and departure) are from Terminal 3.  I am pretty sure that I do not need transit visa at the DXB, however it is no where mentioned on any of their official website.   Can anyone please provide me such a link stating that transiting without leaving the airport does not require visa at DXB, as I need to use this link as a proof for a visa application?  Thanks


I see this on :    I would like to know how is this sorted actually as the amount of "views" apparently doesn't mean that it's frequent.

What is the function of the  sorting option on the Questions tab?


I read many articles related to Stack Overflow reputation, such as the following:   It states:     "The final milestone in this reputation scheme is at 10,000 reputation. At this level, you gain the highest level of privilege possible without being elected a community moderator."   Apart from that my knowledge will increase, I have some questions in mind.   What will happen if someone is elected as a community moderator? Can the reputation help programmers clear a job interview?   Or    Can I sell my reputation for money?    What additional benefits can I get from reputation above 10k?

While users unlock all possible privileges at 20,000 reputation, their privileges are still "enhanced" as their reputation increases. For instance,   An  is granted per 1000 reputation. An  is granted per 2000 reputation.   Are there any other "enhanced" privileges out there that I am missing? It would be great if someone provided an exhaustive list of incremental privileges, as it's difficult to know for sure without sifting through the entire FAQ/privileges page.  At what point does a user gain 100% access to all possible privileges on the site (i.e. the maximum # of delete votes, flags, etc.)?


A thought of mine from class, where not everyone is the "silent kid" type. The teacher would very often need to shout to keep the class barely quiet enough for the students who actually are paying attention. This drives me insane, and I often wish there was a way I could silence the entire classroom.  My idea comes from a feature headphones have, noise cancelling. The way I understand it, a microphone takes in the ambient sound and creates a similar sound at a different phase such that the two sound waves cancel each other out inside the listener's ear. My question is: can I route that other wave back out through a speaker such that the entire class can't communicate the "usual" way? An  suggests that such a device would break conservation of energy, but I could be understanding it incorrectly.

I saw youtube videos that claimed to do this, although I'm quite certain the videos just excluded sound and lied.  However, I am wondering if the physics of this is actually possible - to create a completely negative sound wave that cancels the sound out to a flat line i.e. complete silence.  p.s. I am not referring to white noise, which prevents the sound from being heard by overriding it with a different sound (white noise). Rather, I am referring to making a sound be completely silent by generating the inverse, opposite, or "negative" sound wave.


I have been on StackOverflow for about a month now and I am noticing a pattern. The faster you get your answer in, the more chance you have of getting it upvoted. Even if it is not complete. And generally the more votes your gets, the better chance it has of being accepted.  I initially tried to post quality answers but got tired of my answer being lost to the multitude of similar answers that get thrown in before hand. Only after they have added their one-liner, do they then edit it to add links and examples.  My question is this, is this the way that the site works? Like a flock of birds going after a seed? Does speed really matter more than quality?

I feel like there's a problem with Stack Overflow, as the number of people prowling it increases.  Each question's answers are sorted by descending score and then by descending time of posting. This means that if a person sits down and answers a question in a long, thorough way, going through every nook and cranny, once they post their answer, it will already be one of about seven different ones, some of which have already been upvoted. This wouldn't be a problem if those answers were as thorough as the one this guy's posting, but they usually aren't. Some of them are downright wrong, some aren't even answers to the question asked because their poster didn't bother to read the question all the way through.  This causes a problem I like to call Stack Overflow's Fastest Gun in the West Problem. I've come to a point where I'd rather just send a short, simple, correct explanation, than to go and do some proper research, write a whole blog post about it or even make sure the code I post even compiles, just so it will be noticed, as opposed to the incorrect ones.  I'm sure I'm not the only one doing this and that it despairs many people from even trying to answer questions.  I've long ago learned to try to always raise a problem with a solution in hand, rather than just say "This is a problem, handle it," so my question, after this long tirade, is:     How do you think this can be changed? What would you change in Stack Overflow to make this problem go away without hurting the site?   I promise to vote on answers I like, even if it takes you a long while to post them. :)


We are in the process of evaluating and deciding which Linux to pick for our product for sale. Currently looking at lubuntu. We would possibly ship lubuntu (in lubuntu desktop mode) installed in our embedded product along with our propriety software. Our Software will make calls to the lubuntu for services. Please advise; what would it take in terms of licenses and what we need to do to satisfy Lubuntu requirements. The quantities are in the thousands. More importantly who should I contact in Lubuntu. When I was asked Canonical I was told to talk to Canonical/Lubuntu. But any Lubuntu leads related to this brings you back to Ubuntu/Canonical.  If you have any contact information I would greatly appreciate.

So I am doing a College research project for my Computer Information Systems department and it is about alternative Linux server distribution for small businesses. From my findings I would really like for this research to actually take off into a Distribution project (Using Ubuntu as a base OS).   However I would like to rename the distribution as "Bizbuntu" or something related to that ("Biz" being shorthand for business) however I don't know if I can name the distribution without consent from Canonical.   So my question is do I have to contact Canonical about this, if so, does anyone know a mailing list or email that I can contact them about this?


Let $N$ be a strictly positive integer. How to integrate $\int_0^N \frac{\vert \sin(x) \vert}{x} \ \mathrm{d}x$ ? I tried to subdivise $[0,N]$ in distincts intervals but couldn't achieve a proper resolution of the integral. I have to show that the limit when N tend to $\infty$ is $\infty$ , so I would also accept an answer that could permit to show it.

Improper integral $\sin(x)/x $ converges absolutely, conditionaly or diverges?  We have that $$\int_1^{\infty}\frac{\sin x}{x}dx$$ $$u=\frac{1}{x}$$ $$du=-\frac{1}{x^2}dx$$ $$dv=\sin xdx$$ $$v=-\cos x$$ $$\int_1^{\infty}\frac{\sin x}{x}dx=-\cos(1)-\int_1^{\infty}\frac{\cos x}{x^2}dx$$ $$\int_1^{\infty}\frac{\cos x}{x^2}dx<\int_1^{\infty}\frac{1}{x^2}dx$$ So it converges. Now I need to find out if $\int_1^{\infty}|\frac{\sin x}{x}|dx$ converges or diverges.


I have the string "abigword" and I want to take the array ["ab", "ig", "wo", "rd"]. To generalize, given a string, I want to take the array of its constituent characters paired two-by-two.  What is the most elegant Ruby way to do that?

I have a string (e.g. "AABBCCDDEEFF") and want to split this into an array with each element containing two characters - ["AA", "BB", "CC", "DD", "EE", "FF"].


I've got a pretty simple object I'm trying to unwrap, hardly more than a sphere with some shapes cut out, yet the UV map I'm getting is, well, I'm frankly not even sure what to call that.    I've tried everything I could think of - applied scale, double, triple and quadruple checked both my normals and my seams, removed doubles and deleted loose elements - none of that has helped so far. Changing the method to conformal does nothing as well.  I've also got another similar element in the same scene and that one unwrapped exactly how I wanted it to.   Does anybody have any idea what's going on here? Any help would be greatly appreciated!

I have been looking all aver for this problem and haven't run in to what this is... Normally I mark my seems and I get a nice UVMap ready to texture but sometimes I get this and it is just kicking my butt trying to find a fix.   Sorry if someone already asked this. I just couldn't find what this is and why it only happens sometimes and what is causing this.


If $0 < p < 1$, $f \in L^p$, and $\int \lvert g \rvert^q < \infty$, show that $$\int \lvert fg \rvert \ge (\int \lvert f \rvert^p)^{\frac{1}{p}}(\int \lvert g \rvert^q)^{\frac{1}{q}}$$ My feeling is that I can use $\frac{p-q}{p}$ and $\frac{q-p}{q}$ as a conjugate pair, and apply Holder Inequality to reach such a conclusion. But I tried a lot and failed to get the desired inequality.  I was considering to prove $(\int \lvert fg \rvert )(\int \lvert g \rvert^q)^{-\frac{1}{q}} \ge (\int \lvert f \rvert^p)^{\frac{1}{p}}$, then $(\int \lvert fg \rvert )^{p-q}(\int \lvert g \rvert^q)^{-\frac{p-q}{q}} \ge (\int \lvert f \rvert^p)^{\frac{p-q}{p}}$, i.e. $(\int \lvert fg \rvert )^{p-q}(\int \lvert g \rvert^q)^{\frac{q-p}{q}} \ge (\int \lvert f \rvert^p)^{\frac{p-q}{p}}$.  Seems like dead ends to me..

$0<p<1$   $\dfrac{1}{p}+\dfrac{1}{p'}=1$  If $f \in L^{p}$ and $0<\int_{\Omega}\vert g(x) \vert^{p'}dx < \infty$  then $$\int_{\Omega}\vert f(x)g(x) \vert dx \geq (\int_{\Omega}\vert f(x) \vert^{p}dx)^{\frac{1}{p}}(\int_{\Omega}\vert g(x) \vert^{p}dx)^{\frac{1}{p'}} $$


A game that I'm working on in Unity has a diverse set of spells. The player character and NPCs all use an attributes which modify these spells in different ways. Our design is very fluid and the functions that modify these spells are continuously changing. As of now I've been hard coding the modifying function into the spell class itself while leaving different variables open for designers to modify it. Example for amount of missiles fired:   BaseQty + Strength * MissilesPerStrength   Leaving the BaseQty and MissilesPerStrength attribute open in the inspector for designers.   As our game balancing is changing so much I feel as if only leaving certain variables open isn't enough, as I'll have to go back and change the formula itself if required. I've thought about allowing designers to script the function itself, and for the spell class to get the number for (Example) missiles fired by interpreting the script, but I'm not sure how to go about doing this and in my mind it feels a little bit needlessly complicated for the small team that we are. It's not too much of a hassle to go into the class and change the formula, it just feels wrong not to have it separate.  I'm looking for critique and suggestions on my ideas if possible. Thanks for reading.

My team is switching to Unity 3D for an upcoming project. I'm tasked with converting our game data system into Unity.  Our existing games use spreadsheet documents (Google Docs) for designers to set values and formulas. This is then exported into an XML doc (and obfuscated) and read in by our game client. I'm trying to figure out a way to accomplish this same thing but solely through Unity. Storing, exposing, and reading data through Unity is pretty straightforward but I'm not sure on supporting formulas.  I realize I can write a custom parser and interpreter which can handle formulas but I'm wondering if there is already a way to do this in Unity.  For example, let's say I have a unit with various stats: Level, Max HP, HP, Damage, Victory Reward, etc. That unit may receive a reward after combat which is based on its Level and remaining HP. A designer would be able to enter into the Victory Reward field either a flat value, like 3, or a formula such as "Floor({Level} * ({HP} / {Max HP}))", something like that.  My question is basically, is there an existing solution for handling data with formulas in Unity, via a downloadable asset or something in Unity itself, or is there a simple framework or technology which already can do something like this which can be easily integrated (example: some kind of JSON extension which supports self-referencing other values and basic mathematical/logical operations)?


If a massive body is moving at near light speed (or, hypothetically at light speed) and on course to hit Earth, will we feel its gravitational pull before it collides with us?  I think the answer is no because speed of gravity is same to speed of light.  Does it mean bodies moving at near light speed don't produce gravity?  From the comments>>>  if change of gravity propagates at the speed of light, and an object is moving at near light speed, does that change how much gravity there is ahead of that object?

If the strength of gravitational influence exerted by a body is derived from its mass and energy then is it true that a moving object which has some kinetic energy should also produce stronger gravitational pull than a static/slower one?  If that's correct then would it be also possible for an object moving fast enough to produce gravity so strong that it would collapse into a (fast moving) black hole?


What is the dual space of  $C([0,T];X)$, where $X$ is a Hilbert space? Is it $\operatorname{BV}([0,T]; X^*)$?  As we know, for $C([0,T])$, the dual space is $\operatorname{BV}([0,T])$,  but when it is continuous with vector values in $X$, is it still true?

A version of the Riesz Representation Theorem says that a continuous linear functional on the space of continuous real-valued mappings on a compact metric space, $C(X)$, can be identified with a signed Borel measure on the set $X$. Are there any similar results when we replace $C(X)$ by the space of continuous functions of $X$ (compact metric) into $Y$ when (1) $Y=R^N$ or in general (2) $Y$ is a Banach space? I suspect the answer is yes, but I would like to find the right reference to start looking at. Thanks.


Prove that $\mathbb{Q}[\sqrt{3}, \sqrt{5}] = \mathbb{Q}[\sqrt{3}+  \sqrt{5}]$  Take $x \in \mathbb{Q}[\sqrt{3}+  \sqrt{5}]. x = a_x + b_x( \sqrt{3} + \sqrt{5}) = a_x + b_x\sqrt{3} + b_x\sqrt{5} \in \mathbb{Q}[\sqrt{3}, \sqrt{5}] \Rightarrow \mathbb{Q}[\sqrt{3}+  \sqrt{5}] \subset \mathbb{Q}[\sqrt{3}, \sqrt{5}] $  I am having trouble proving the other inclusion.

Here is an extract from my Galois Theory notes proving that $\mathbb{Q}(\sqrt{5}, \sqrt{6}) = \mathbb{Q}(\sqrt{5}+ \sqrt{6}) $  My question is after rearranging equation (1) has my lecturer omitted an $\alpha$ that should be on the denominator? I think this may be a typo but solutions to the general case in one of our assignments have been released and it is also missing the $\alpha$ in the denominator.  If it is not a typo then how does this equation hold  thanks in advance


Einstein postulates that the light travels at the same speed $c$ in every inertial frame of reference. Now, if I'm within a train which goes right with velocity $V$ and throw a ball to the right with velocity $v_1$, the ball's velocity on my reference frame would be $v_1$. And from outside the train its velocity would be $V + v_1$. Now what if (from inside that same train) I turn a lantern on to the front of the train. How come the photon doesn't have velocity $V + c$? What is being "sacrificed" in order to keep the photon's velocity equal to $c$?

The title says it all.  If I was on a bus at 60 km/h, and I started walking on the bus at a steady pace of 5 km/h, then I'd technically be moving at 65 km/h, right?  So my son posed me an interesting question today: since light travels as fast as anything can go, what if I shined light when moving in a car?  How should I answer his question?


I am a little bit confused about photon particle/wave duality. Do we have to interact with photon to detect it? Or without interacting photon, only by its wave nature, can we detect the existence of a photon. Consider the following image:  Can detector2 at a sufficient distance, detect the moving photon in a way?

I am thinking about a detector that would beep if light passes through it. Is it possible?


I ran a full backup on SQL server 2008, but the transaction log stayed in tact. I though a full backup would make a new transaction log. What do I need to do to get my trn to a normal size?

This one seems to be a common question in most forums and all over the web, it is asked here in many formats that typically sound like this:  In SQL Server -  What are some reasons the transaction log grows so large? Why is my log file so big? What are some ways to prevent this problem from occurring? What do I do when I get myself on track with the underlying cause and want to put my transaction log file to a healthy size?


When I was younger (early 2000s), I read a young adult novel about a post-apocalyptic earth where the people live in small domed cities because of nuclear fallout and play war games to decide who owns any new clean land.    The main character has been bred to be the best at the game. He has the power to detect the magnetic field of the board pieces which is a requirement to play. He loses his powers for some reason but then wins anyways because his country or teammate cheats and then goes and lives on the island that he won.

Some sort of battle school (no, not Ender's Game), where teens are being trained as military commanders.   The control system for their army hinges around some sort of system that requires extremely fine motor control -- being able to "push" around digital representations of military units using a special interface that interprets minute finger movements.  The boy protagonist eventually meets a girl in the battle school, and is astonished to learn that most people do not live as well as he does -- for instance, he gets a fresh jumpsuit outfit every day and disposes of the old one; this is a luxury.  One scene I recall is them kissing for a moment in some sort of underground passageway; the boy protagonist notes the exact length of the kiss, as he has been trained to have heightened time perception.  I don't recall much about other commander characters; I think they have different special abilities, and one other major character might have physical deformities, possibly because of postwar-radiation-related birth defects.  They have been training for an upcoming, prearranged final battle between all the existing national governments; the military units are very possibly robotic or entirely digital in nature, so as to avoid wasting materiel / human life.    They ultimately win the battle, just barely; I think the girl protagonist gives them an edge in the competition by hacking the timing / control system in favor of their team, causing a discrepancy which only the boy protagonist notices due to his heightened perceptions.  It was agreed that the winning government gets dominion over one of the few islands of land left that was not irradiated in some previous war; the protagonists get to live there as a reward for their victory.  I believe the boy protagonist later realizes he's gradually losing his ability to exactly quantify the passage of time.  Published no later than 2004, likely somewhere between 1980-2000, probably sometime in the '90s.