Email address regular expression validations

How to update the following regular expression /^([a-zA-Z0-9_\-\.]+)@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.)|(([a-zA-Z0-9\-]+\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\]?)$/ to accept the "+" in the email address.  Now:   abc@gmail.com // true  abc+100@gmail.com // false  What I need   abc@gmail.com // true  abc+100@gmail.com // true  My Code:   export const handleEmailValidation = (email) => {   const validEmailAddress = /^([a-zA-Z0-9_\-\.]+)@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.)|(([a-zA-Z0-9\-]+\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\]?)$/;   const containAt = /^((?!@).)*$/;   const lastAt = /^[a-z|A-Z|0-9]+[^@]\s?@{1}$/;   if (containAt.test(String(email).toLowerCase())) {     return 'An email address must contain a single @ ';   }   if (lastAt.test(String(email).toLowerCase())) {     return 'Please enter a valid value after the @ ';   }   if (!validEmailAddress.test(String(email).toLowerCase())) {     return 'Please enter a valid email address';   }   return ''; };


To Check if Org-wide email is verified in APEX

I have created a picklist with selectOptions as Org-wide email address as below  VF Code  <apex:selectList value="{!emailFromAddress}" size="1" multiselect="false">               <apex:selectOptions value="{!OrgWideEmailAddress}"></apex:selectOptions> </apex:selectList>   Controller Code  public List<selectoption> getOrgWideEmailAddress(){         List<SelectOption> lstEmailIds = new List<SelectOption>();          // Use Organization Wide Address         for(OrgWideEmailAddress owa : [select id, Address from OrgWideEmailAddress]) {            lstEmailIds.add(new SelectOption(owa.id,owa.address));         }        return lstEmailIds;     }   The selected email Address Id is used to set as OrgWideEmailId for an email as below  Messaging.SingleEmailMessage message = new Messaging.SingleEmailMessage(); mail.setOrgWideEmailAddressId(emailFromAddress);   But when i select a Non verified email address then email sending fails. Hence i want a way to filter & get only verified email address to show in Picklist options.  Tia.


The exchange of photons gives rise to the electromagnetic force

Pardon me for my stubborn classical/semiclassical brain. But I bet I am not the only one finding such description confusing.  If EM force is caused by the exchange of photons, does that mean only when there are photons exchanged shall there be a force? To my knowledge, once charged particles are placed, the electromagnetic force is always there, uninterruptedly. According to such logic, there has to be a stream of infinite photons to build EM force, and there has to be no interval between one "exchange event" to another. A free light source from an EM field? The scenario is really hard to imagine.  For nuclei the scenario becomes even odder. The strong interaction between protons is caused by the exchange of massive pions. It sounds like the protons toss a stream of balls to one another to build an attractive force - and the balls should come from nothing.  Please correct me if I am wrong: the excitations of photons and pions all come from nothing. So there should be EM force and strong force everywhere, no matter what type of particles out there. Say, even electrical neutral, dipole-free particles can build EM force in-between. And I find no reason such exchanges of particles cannot happen in vacuum.   Hope there will be some decent firmware to refresh my classical brain with newer field language codes.


How can I remove or change question marks in text for mysql and php?

The call:  <?php echo nl2br($post['post_text']); ?>   Creates a load of question marks inside a diamond on my blog, how to fix?


Split and iterate over array and match a value

I want to be able to filter products based on one of a, b, c, or d matching the value of `this.listFilter'  I think the code below is almost doing what I want, the split function returns an array but only seems to be matching on the first element in the array, I need to iterate over each element and check if it matches the value of this.listFilter.  The breadcrumb array contains:  breadcrumb[    'a > b > c > d' ]  return this.products.filter((product: IProduct) => product.categories.category.breadcrumb[0].split(' > ').indexOf(this.listFilter));    Can anyone suggest a way to iterate over the array split by the " > " and check against the value of this.listFilter?


If $G$ is a group of order $|G|=10^6$, then $G$ cannot be simple. I hame hoping to get feedback on my proof attempt; I am using: Lemma: Let $|G|=p^am$, where $a>1$ and $m>1$. Assume $G$ is simple, then the following are satisfied:  $n|m$ $n \equiv 1 \pmod p$ $|G|$ divides $n!$ where $n=n_p(G)$  Proof: Assume $G$ is simple with $|G|=10^6=2^6 \cdot 5^6$. We can apply the Lemma from above with $p=5$. Let $n=n_5(G)$. Then, $n\mid 2^6=64 \implies n \in \{2^1,2^2,2^3,2^4,2^5,2^6\}$. Since $n \equiv 1(\mod 5)$ and $10^6\mid n!$, then $2^4 \equiv 1(\mod 5)$ (no other powers of 2 fit this way). Since we assumed that $G$ is not simple, then $n \neq 1$. Thus, $n=2^4=16$. To see if $10^6\mid 16!$, we can look at $5^6\mid 16!$. $16!=1 \cdot 2 \cdot 3 \cdot 4 \cdot 5 \cdot 6 \cdot ... \cdot 10 \cdot ... \cdot 15 \cdot 16$. Clearly, there are three $5$'s contained in $16!$.  $\therefore$ The largest power of $5$ to divide $16!$ is 3.  $\therefore$ $G$ is not simple.


How do I effectively solicit a strong letter of recommendation from a professor?

I have been asked to write many letters of recommendation over many years.  In some cases, the requesters have made this task easy and enjoyable, and others, less so. I'd like to offer some guidelines that work for me, and solicit others.


Unit testing code with a file system dependency

I am writing a component that, given a ZIP file, needs to:   Unzip the file. Find a specific dll among the unzipped files. Load that dll through reflection and invoke a method on it.   I'd like to unit test this component.  I'm tempted to write code that deals directly with the file system:  void DoIt() {    Zip.Unzip(theZipFile, "C:\\foo\\Unzipped");    System.IO.File myDll = File.Open("C:\\foo\\Unzipped\\SuperSecret.bar");    myDll.InvokeSomeSpecialMethod(); }   But folks often say, "Don't write unit tests that rely on the file system, database, network, etc."  If I were to write this in a unit-test friendly way, I suppose it would look like this:  void DoIt(IZipper zipper, IFileSystem fileSystem, IDllRunner runner) {    string path = zipper.Unzip(theZipFile);    IFakeFile file = fileSystem.Open(path);    runner.Run(file); }   Yay! Now it's testable; I can feed in test doubles (mocks) to the DoIt method. But at what cost? I've now had to define 3 new interfaces just to make this testable. And what, exactly, am I testing? I'm testing that my DoIt function properly interacts with its dependencies. It doesn't test that the zip file was unzipped properly, etc.  It doesn't feel like I'm testing functionality anymore. It feels like I'm just testing class interactions.  My question is this: what's the proper way to unit test something that is dependent on the file system?  edit I'm using .NET, but the concept could apply Java or native code too.


InputStream & OutputStream throwing null pointer exception?

My code seems to be throwing a null pointer exception when attempting to copy an existing file to a new location; the new file will also be named based on the current date of execution.   Any ideas?  public static String returnScreenshotName() {     return (System.getProperty("user.dir") + "\\target\\output\\imgs\\" + screenshotName); }  private static void copyFileUsingStream(File source, File dest) throws IOException {     InputStream is = null;     OutputStream os = null;     try {         is = new FileInputStream(source);         os = new FileOutputStream(dest);         byte[] buffer = new byte[1024];         int length;         while ((length = is.read(buffer)) > 0) {             os.write(buffer, 0, length);         }     } catch (IOException ignored) {     }     finally {         is.close();         os.close();     } }  public static void copyLatestExtentReport() throws IOException {     try {         Date d = new Date();         String date = d.toString().replace(":", "_").replace(" ", "_");         File source = new File (System.getProperty("user.dir") + "\\output\\report1.html");         File dest = new File (System.getProperty("user.dir") + "\\output\\" + date + ".html");         copyFileUsingStream(source, dest);     }catch (IOException ignored) {     }


Is it possible to have SQL server look for entities under other schemas than DBO when the schema name isn't specified in the query?

Not sure if this is a thing, and I understand it's better practice to write your queries using the two-part naming convention, but it would be cool if SQL Server had a way to setup a schema priority list.   That way when you execute a query that references entities without their correlating schemas, the server is smart enough to search for those entities in each schema on the priority list, in order, until it finds the entity.  I would find this mostly helpful in a lot of ad-hoc queries I write that won't ever be formalized.


EXE files. How to run exe files in ubuntu?

im new to linux, so I wanted to ask, how to run exe files. Yeah yeah I seen wine. But its opening but, I cant do anything... I mean its like, broken. Idk how to say that, hope u help. (Ubuntu 20.4)


How to computer $\int_0^1\log(\sin \pi x)\text{d}x$ under complex methods.

the below integral is coming from M.Stein's complex analysis. chapter 3 exercise 9.  Show that $$\int_0^1\log(\sin \pi x)\text{d}x=-\log 2$$ use the contour shown in the above figure  Then I recall the definition of $\log(z)$,it must be defined on a simply connected domain $\Omega$ with $1\in \Omega$ and $0 \not\in \Omega$. In order to use the above contour to computer the integral. maybe consider $\int_{\gamma}\log(\sin \pi z)\text{dz}$,where $\gamma$ is the contour. but for $z=0$, there is no definition.   I think the author arrange the exercise here must expect the reader use residue formula to computer it. but I don't know how to. thanks very much


Proving the fact that a continuous function is identically 0 while we are given an inequality.

$f \in C[a,b]$. There exists $M \geqslant 0$ such that $|f(x)| \leqslant M \int_a^x|f(t)|dt$  $\forall x \in [a,b]$. It is be proved that $f(x) = 0$ $\forall x \in [a,b]$. If $M = 0$, nothing to prove. Otherwise, let $K$ be such that $|f(x)| \leqslant K$. We observe that $|f(x)| \leqslant MK(x-a)$. I am not able to go any further.


Screenshot w/highlighting feature wanted

There are two super nice features on my iPhone:  ability to take a screenshot with a hardware button combo; ability to highlight it with a semitransparent brush;  It enables me to take screenshots and draw "attention areas" over them. There is a nearly same feature in Windows with Snipping Tool (much less convenient though). Is there a way in Ubuntu to:  run some tool via keyboard shortcut; take a screenshot of some area on the screen; highlight important area with a semitransparent brush.


How to add lightning Application on Salesforce1 Tabs?

In a project i am working on, want to add lightning application in salesforce1 tabs(Custom tabs). Please help me out in this.


Who Collected all the stones before thanos did?

In Thor: Ragnarok an infinity gauntlet was visible, does this mean Odin had it in the first place? Was he the one who put the stones in different realms?


First time I get Ubuntu to load up without having to change secure boot, UEFI but it doesn't detect my preinstalled Windows 8 on the hard drive. The option to install alongside Windows isn't available but cleaning the whole disk is always highlighted.


Is there any command i should use to do this or am i just out of luck?  have looked at Jupiter but it seems to be obsolete. Is there another program i could install? If so please tell me the name of it...   Also, I am trying to do this so I can game on my laptop again. I am trying to play Borderlands The Pre Sequel.  Not sure if that information will help, but I will add it just in case.   Jupiter is not supported I have no idea what i am doing.   (What do I have to do to submit this question!?!)


Logistic regression output and probability

What is the interpretation of the number that is the output of the logistic regression function?   The logistic function   $$f(\vec{x}) = \frac{1}{1+e^{-g(\vec{x})}}$$  (where $g$ is a linear function) is supposed to map a continuous variable (or more generally a whole bunch of totally ordered variables) to between 0 and 1.  I've always assumed it is the probability of inclusion in one set or the other. The range is $[0,1]$ (well, maybe not 0 and 1), which is what a probability is. And frankly anything between 0 and 1, what else could it be other than a probability.   But looking at the curve, I started to doubt. I wondered if it is necessarily to be interpreted as a probability. It looks like a probability but is it really? Just because they share the same range doesn't mean they are the same. If $f(\vec{x}) = .75$, does that really mean that $75\%$ of $f$ is less than $f(\vec{x})$?  This could go in two directions:   Suppose it is a probability, or more exactly the probability of a 'true', '1', or 'positive' classification of a point in the domain. How is this justified? Suppose not. Then what is it exactly and why? How far a way is it from a probability (numerically and conceptually)?   Another way to say this is what is so special about $1/(1+e^{-g(x)})$? Why not any monotonically increasing odd (about $y=1/2$) function with the same range, like  $$f(x) = \frac{\tan^{-1}(g(x))+\pi/2}{\pi}$$ or $$f(x) = {\rm erf}(g(x)) = \frac{2}{\sqrt{\pi}} \int_{-\infty}^x e^{-t^2} \ {\rm d}t$$ (very close but not equal to the logistic function)     or frankly  $$f(x) =  \begin{array}{ll} 0,& {\rm if\  } g(x) < 0\\ 1,& {\rm if\  } g(x) >= 0 \end{array}$$ ?


I am running the following command line: myuser@server:/var/www/html/folder/htdocs$ php remove.php myuser is not in the sudoers file.  This incident will be reported.  Within remove.php I run: exec('sudo -u myuser /usr/bin/wipe '.$main_path.$base.' -f -c -s'); And I've set my sudoers file: www-data ALL=(myuser) NOPASSWD: ALL And I've set sudoers to 0440: -r--r-----   1 root root        838 Sep 18 11:07 sudoers Why am I told that myuser isn't in the sudoers file when it is?


Vertices stand out of object while animating!

Hello blender community. First, sry for my bad english, hope you understand it anyway. Second, I have a problem animating my object. Everytime I use the foot IK controller, my mesh deforms in a weird way.    Or when I move the whole mesh      I already tried weight painting but that doesn't change anything. Can someone help me please?


Dynamically size arrow \mapsto in function definition

I have the following diagram:    However, this looks a bit ugly, I would like a version that looks a little bit better. For example, size the last arrow such that the T_\phi is moved to the right.  This is the code which I am using to do this:  \begin{align*}   \xi \colon &\lb \to \mathcal{L}(\hh)\\   &\phi \mapsto T_\phi. \end{align*}   Where \lb and \hh just give the names for those spaces. Does anybody have a suggestion how I would improve the look of this function definition?


The infinite tetration of ${x}$ basically means that we take a value and we continue to raise the value to its power forever. If that sounds confusing, it can be thought of as infinite repeated exponentiation of ${x}$. Now, my question is, will this value converge for any vale of ${x}$? In other words, is there a value that this will get infinitely close to when ${x}$ is a certain value?


Why can a class member lost its value in Android?

Can someone explain me why can sometimes this exception happen?  Exception java.lang.NullPointerException: Attempt to invoke virtual method 'long java.util.Date.getTime()' on a null object reference  ChannelEPGF$myPagerAdapter.getItem (ChannelEPGF.java:82) (find the "//THIS IS THE 82. rows" text in my code)  here is my code:      import android.os.Bundle;     import android.support.v4.app.Fragment;     import android.support.v4.app.FragmentManager;     import android.support.v4.app.FragmentPagerAdapter;     import android.support.v4.view.ViewPager;     import android.view.LayoutInflater;     import android.view.View;     import android.view.ViewGroup;     import com.mp.myapp.DataTypes.ChannelEPG;     import java.util.Date;      public class ChannelEPGF extends Fragment implements ChannelEPG.fragmentCommunicator {     private Date selectedDate;     private String channelId;     private String channelTitle;     private ViewPager pager;     private boolean isTunable;      @Override     public void sendMessage(String name, Object msg) {             if (msg != null) {                     ChannelEPG item = (ChannelEPG) msg;                     channelId = item.GetId();                     channelTitle = item.GetTitle();                     isTunable = item.GetTunable();             } else {                     pager.getAdapter().notifyDataSetChanged();             }     }      @Override     public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {             View v = inflater.inflate(R.layout.activity_channel_epgf, container, false);              pager = (ViewPager) v.findViewById(R.id.viewPager);             if (pager != null) {                     pager.setAdapter(new myPagerAdapter(getChildFragmentManager()));                     pager.setCurrentItem(1);             }              return v;     }      private class myPagerAdapter extends FragmentPagerAdapter {              public myPagerAdapter(FragmentManager fm) {                     super(fm);             }              @Override             public Fragment getItem(int pos) {                     if (pos == 0) {                             selectedDate = new Date();                             selectedDate.setTime(selectedDate.getTime() - 24 * 3600 * 1000);                             return ActivityChannelEPG.newInstance(selectedDate, channelId, channelTitle, isTunable);                     } else if (pos == 1) {                             selectedDate = new Date();                             return ActivityChannelEPG.newInstance(selectedDate, channelId, channelTitle, isTunable);                     } else if (pos == 2) {                             selectedDate = new Date();                             selectedDate.setTime(selectedDate.getTime() + 24 * 3600 * 1000);                             return ActivityChannelEPG.newInstance(selectedDate, channelId, channelTitle, isTunable);                     } else {                             selectedDate.setTime(selectedDate.getTime() + 24 * 3600 * 1000); //THIS IS THE 82. rows                             return ActivityChannelEPG.newInstance(selectedDate, channelId, channelTitle, isTunable);                     }             }              @Override             public int getCount() {                     return 8;             }              public int getItemPosition(Object object) {                     return POSITION_NONE;             }     }   }


How to find out why a websites organic ranking went down?

I was given a task to find out why a website suddenly had a drop in their organic ranking.  A company specializing in SEO sent my client an email about the organic ranking drop.  They had a chart showing a big drop from December 2017 to January 2018.  The client has no previous records of their organic ranking or of the SEO used and updated on the website.  How did this company find a chart to track my clients websites organic ranking?  I am trying to use google webmaster tools and semrush to look into this since I am quite new to SEO implementation.


Can we compare a string with == to an empty value

Lets say we have a string in java. Can we compare this string to "" using the ==? For example:  String myString = ""; if(myString == "");


It there a possible way that I could scale all the objects individually?

I'm working on a complicated building which my goal is to keep the multiple objects in their respective groups and scale all objects at once. Instead of using Ctrl+J function to group everything into 1 object and scale it.   Appreciate some advice. Thanks.


How to match cmyk colors between matplotlib and LaTeX

I'm plotting something using matplotlib and I'm using the matplotlib.cm.rainbow colormap. I need to match the same colors in my LaTeX document, but I'm having a difficult time making the colors match between what I get on my plot and what appears in my LaTeX document.  What do I have to do to get matplotlib and LaTeX to use the same colors? Even coming close would be a benefit.  The code I'm using to plot in matplotlib is:  import matplotlib.pyplot as pyplot  Fig, ax = pyplot.subplots() indices = range(8)  length = len(indices) print("\ncolors: ") for i in range(length-1):     left = indices[i]     right = indices[i+1]      c = pyplot.cm.rainbow(i/length)     print("i={}, color={}".format(i,c))     ax.fill_between((left,right), 0,1,                     facecolor=c, edgecolor=c, alpha=0.25)  # Do the last one i +=1 left = indices[i] right = 8 c = pyplot.cm.rainbow(1.0) print("i={}, color={}".format(i,c)) ax.fill_between((left,right), 0,1,                 facecolor=c, edgecolor=c, alpha=0.25)   The output from this is:  colors:  i=0, color=(0.5, 0.0, 1.0, 1.0) i=1, color=(0.24901960784313726, 0.38410574917192586, 0.98063477046897773, 1.0) i=2, color=(0.0019607843137254832, 0.70928130760585339, 0.92328910610548931, 1.0) i=3, color=(0.25294117647058822, 0.92563765978155632, 0.83018403081555059, 1.0) i=4, color=(0.50392156862745097, 0.99998102734872685, 0.70492554690614728, 1.0) i=5, color=(0.75490196078431371, 0.92090551794495368, 0.55236497296050591, 1.0) i=6, color=(1.0, 0.70054303759329106, 0.37841105004231035, 1.0) i=7, color=(1.0, 1.2246467991473532e-16, 6.123233995736766e-17, 1.0)     I use the output to define colors in LaTeX using:   \definecolor{colorA}{cmyk}{0.5    , 0.0    , 1.0     , 0.0} \definecolor{colorB}{cmyk}{0.2490 , 0.3841 , 0.9806  , 0.0} \definecolor{colorC}{cmyk}{0.0019 , 0.7092 , 0.9232  , 0.0} \definecolor{colorD}{cmyk}{0.2529 , 0.9256 , 0.8301  , 0.0} \definecolor{colorE}{cmyk}{0.5039 , 0.9999 , 0.7049  , 0.0} \definecolor{colorF}{cmyk}{0.7549 , 0.9209 , 0.5523  , 0.0} \definecolor{colorG}{cmyk}{1.0    , 0.7005 , 0.37841 , 0.0} \definecolor{colorH}{cmyk}{1.0    , 1.2246 , 6.12323 , 0.0}   Finally I use the colors in a table (with the colortbl package) using the command  \rowcolor{colorA!25} 1 & ...    However, the colors in the figure don't match the colors in the table and it is aggravating me why it doesn't work. Instead of the purple, blue, aqua, ... (I know these are not technical color names) that is seen in the figure, the colors I'm getting are green, orange, orange red, red, gray red, violet, blue,... The colors are not even close.


Referencing titles that include sparse quotes

I don't come across this particular problem very often, but everyonce and a while I come across a journal article that contains sparse/double quotes around a particular word.  In particular this is problematic when the quotes are in place around the first or last word because some reference styles enclose titles of journal papers or one level of series or book or chapter in “”.   Three observations:   It makes no sense to me to include back to back open quotes: ""XYZ" the remainder of the title" Most reference managing software (some written by people with extensive knowledge of bibliographic rules) will strip off leading or even embedded quotations. Medline’s and web of science’s citation databases show many titles I have had issues with, without the quotations.   Any suggestions on the best way to handle this in general.    Updates:     I do not believe this is a duplicate of  because my question is very specific to a bibliography.  I'm not asking about paragraph embedded references, this is specific to how referencing styles tolerate changes to titles or formatting requirements which were deliberately written with specific punctuation or rule set, respectively. To me, this indicates the flexibility to altering the rules or the citation, may not be transferable and needs an explicit justification or rule.


Best price or exact match, How market order would be matched when all are limit orders?

Suppose, there is a Limit sell order with Limit Price : 21, Qty   : 21000  then another new Limit sell order placed as below Limit Price : 20, Qty   : 200  Now if a new limit buy order placed as below, Limit price : 21, Qty : 400  I agree, buy Limit order should match with Lowest sell order available. But If buy limit order has exact match available with Limit sell order, then with whom buy order should match? i.e Which order should get high profit buy order or sell order in case there is a exact match order?


How can I embed a webpage in a MS Word Doc

All,  Is there any way of embedding a webpage in a MS Word 2007 document, similar to having an iFrame object in the Word doc, with any changes to the underlying webpage being updated as appropriate?  Many thanks for any help on this


Running executable jar file from terminal

I've just got a new PC running Ubuntu 16.04 and have transferred my work from my laptop running Ubuntu 14.04.  I have an executable jar file called timed_hri.jar.  On my laptop I can go to the directory and type ./timed_hri.jar and it runs. However, on my desktop it doesn't, I need this to run as I have a Python script that relies on using the ./ command on the file.  This is the output when I try it on my PC:  ./timed_hri.jar: line 1: $'PK\003\004': command not found ./timed_hri.jar: line 2: $'\bne\355H': command not found ./timed_hri.jar: line 3: syntax error near unexpected token    `$'NX\252\276!\227\230iP\275餰  \364g\354\002aF\325\\\213G\263\225\3021B\305Q\237\336\337\375\301t\367\315 N?\372\275Z\235\031BB\3452/\231\241\266\377Z'' ./timed_hri.jar: line 3:me�H6�8��META-INF/MANIFEST.MFM��!{��R                                                               ȝƨ�!51��֬�^C�˂�/VZ��{(NX��!��iP�餰�g�aF�\�G���1B�Q�����t��N?��Z�BB�2/����Z'


Im stuck with this very simple code were I'm trying to create a function that takes a parameter and adds 1 to the result and returns it but somehow this code gives me no results. (I've called the function to see if it works.)  Somebody please help me since I'm very new to python :)  def increment(num):     num += 1 a = int(input("Type a number ")) increment(a)`   I changed it to   def increment(num):     return num + 1 a = int(input("Type a number ")) increment(a)`   but still no results are showing after I enter a number, Does anybody know?


If I use a food thermometer to insure the food is cooked can I use a toaster oven instead of an oven to bake and grill any food?

When I buy frozen fish it says "do not use toaster oven". There are warning labels on frozen hamburger packs as well as packs of frozen fish. As long as I check the temperture of the fish, meat , cake or what have you can I assume the food is safe to eat as I would in a regular oven?


Why is physical space equivalent to $\mathbb{R}^3$?

Why is physical space equivalent to $\mathbb{R}^3$, as opposed to e.g.  $\mathbb{Q}^3$?  I am trying to understand what would be the logical reasons behind our assumption that our physical space is equivalent to $\mathbb{R}^3$ or 'physical straight line' is equivalent to $\mathbb{R}$ .   The set of reals $\mathbb{R}$  is a basically an algebraically constructed set, which is nothing but the completion of $\mathbb{Q}$, the set of rationals. For reference see here . Now my question is what is the reason behind our approximation of the physical space by this abstract set. Why is this approximation assumed to be most suitable or good approximation?


I am trying to add data to the SQLite database but when I add the data it gives me null pointer exception.  This is the error in the logcat  java.lang.NullPointerException: Attempt to invoke virtual method 'java.io.File android.content.Context.getDatabasePath(java.lang.String)' on a null object reference  enter code here  package com.llmago.autism;  import android.content.Context; import android.content.SharedPreferences; import android.os.Bundle;  import androidx.fragment.app.Fragment;  import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import android.widget.Button; import android.widget.EditText; import android.widget.TextView; import android.widget.Toast;  import java.util.Objects;   public class StartFragment extends Fragment {      private EditText edtName, edtAge, edtScore;     private Button save, load;       Db db = new Db(getActivity());      public StartFragment() {         // Required empty public constructor     }       @Override     public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {          View view = inflater.inflate(R.layout.fragment_start, container, false);          initUI(view);         // Inflate the layout for this fragment         return view;     }      public void initUI(View view) {         edtName = view.findViewById(R.id.name);         edtAge = view.findViewById(R.id.age);         edtScore = view.findViewById(R.id.result);           save = view.findViewById(R.id.save);         save.setOnClickListener(v -> btnSaveAction(view));      }      public void btnSaveAction(View view) {         String name = edtName.getText().toString();         String age = edtAge.getText().toString();         String score = edtScore.getText().toString();          boolean result = db.insertData(name, age, score);         if (result == true) {             Toast.makeText(getActivity(), "Done", Toast.LENGTH_LONG).show();         } else {             Toast.makeText(getActivity(), "Error", Toast.LENGTH_LONG).show();         }      } }          package com.llmago.autism;  import android.content.ContentValues; import android.content.Context; import android.database.sqlite.SQLiteDatabase; import android.database.sqlite.SQLiteOpenHelper;  import androidx.annotation.Nullable;  public class Db extends SQLiteOpenHelper {       public static final String databaseName = "autism.db";          public Db(@Nullable Context context) {         super(context, databaseName, null, 1);      }      @Override     public void onCreate(SQLiteDatabase db) {          db.execSQL("create table autism(id INTEGER PRIMARY KEY AUTOINCREMENT, name TEXT, age TEXT, score TEXT)");      }      @Override     public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) {          db.execSQL("DROP TABLE IF EXISTS autiusm");         onCreate(db);     }      public boolean insertData(String name, String age, String score){          SQLiteDatabase sqLiteDatabase = this.getWritableDatabase();         ContentValues contentValues = new ContentValues();          contentValues.put("name", name);         contentValues.put("age", age);         contentValues.put("score", score);          long result = sqLiteDatabase.insert("autism", null, contentValues);          if (result == -1)             return false;          else             return true;      } }


How can we set html contents into an Iframes body?

How can we set html contents into an Iframes body, instead of call a url of a page by its src attribute? Note: I want a perfect code, i mean that should able to work in all browsers.


I have a Asus EEE PC Netbook, 1015CX. I have created a bootable usb to try Ubuntu and to test how it looks.  The main problem is that the screen resolution is locked at 800x600 where as my netbook usually runs at 1024 minimum. How can I change it? I see no option in the menu.


How do I capture artificial light sources better?

I am quite new to photography and was looking into how I can take better indoor photographs, particularly around night time.  I'm currently in a hotel room for the night and decided to try and take a picture of my room to test out my tripod which I haven't used before. However I noticed no matter what I set my camera settings to the artificial lights (particularly the lamp on the left, image attached) just appeared very washed out. You can't tell any detail about the lamp shade all you can see is just some sort of light but not much to it.  I tried a variety of fstop/shutter speed settings and tried a variety of ISO settings but they all appeared pretty much the same unless I massively underexposed the image.  Given that I wondered whether the solution would be to take a HDR image or take a normal exposure and an underexposed image and blend them later? I understand that artificial light like this can be very hard and harsh but I wondered if there's a way of improving the result with looking away from it?  I wasn't trying to take any particular special picture here but just test out my camera a bit more but this was the first thing I noticed and I didn't know how to fix it. Any tips would be greatly appreciated.


If you have a conserved quantity, why can't you use it to eliminate a variable in the Lagrangian?

Suppose, for example, we take a particle in polar coordinates $(r, \theta)$ with a central force, so $U = U(r).$ The Lagrangian is $$\mathcal{L} = \dfrac12 m (\dot{r}^2 + (r\dot{\theta})^2) - U(r).$$  The corresponding equation of motion for $r$ is $$m\ddot{r} = m\dot{\theta}^2r - \dfrac{\mathrm{d}U}{\mathrm{d}r}.$$  Using angular momentum conservation, $L = mr^2 \dot{\theta}$ is constant, so we can use it to eliminate $\dot{\theta}$ and obtain $$m\ddot{r} = \dfrac{L^2}{mr^3} - \dfrac{\mathrm{d}U}{\mathrm{d}r}.$$  However, suppose we return to the original statement of the Lagrangian and  eliminate $\dot{\theta}$ there. Then we'd have $$\mathcal{L} = \dfrac12 m\left(\dot{r}^2 + \dfrac{L^2}{m^2r^2}\right) - \dfrac{\mathrm{d}U}{\mathrm{d}r}.$$  Applying the Euler-Lagrange equation $\dfrac{\mathrm{d}}{\mathrm{d}t}\dfrac{\partial \mathcal{L}}{\partial \dot{r}} = \dfrac{\partial \mathcal{L}}{\partial r}$ to the above, $$m\ddot{r} = -\dfrac{L^2}{mr^3}-\dfrac{\mathrm{d}U}{\mathrm{d}r}.$$  This is wrong; we can't eliminate $\dot{\theta}$ in the Lagrangian this way before applying the Euler-Lagrange equations, but why not?


I can't open Blender 2.8 files after I save them. Because it tries to open with 2.79

Blender 2.79b is installed (from .exe) on my computer, currently. And I just downloaded the Blender 2.8 release candidate 2 (.zip).  When I create something in Blender 2.8, after I save it, I cannot open it again because the computer tries to open the blend file in version 2.79b. And manually selecting the 2.8 version from zip file does not work.  How can I open my blender 2.8 files? Do I have to delete Blender 2.79b?


I’m working on a named sword that makes something happen when you hold it. The sword is enchanted, but it seems my code isn’t working. Is there a specific thing I need to add if the sword is enchanted and named? My current code is: execute as @a[nbt={SelectedItem:{id:"minecraft:iron_sword",tag:{display:{Name:'{"text":"Escargot"}'}}}}]


Create a new answer order that considers vote count, how old it is, and answer count

This proposal tries to solve   If a new answer to an old question with lots of answers gets a few upvotes, it is a strong indicator that the answer is good:   it is much more recent than the fastest guns, and so had less time to get upvotes (consider how old it is) it is way further down than the fastest guns, so much fewer people have viewed it (consider answer count)   For questions less than 8 short answers or so, it does not matter much to me: my attention span is enough to scan them all.  But for larger questions, it would help. Specially on the "new technology came out that perfectly answers the question" scenario.  One may argue that such questions should be closed as too broad, but let's not touch that question here and suppose that they are valid (I think many are). In any case, as time tends to infinity, the answer count per question also does, so we either deal with it some day, or start closing them at some point.  I know it is not easy to come up with a sensible metric, and I'm not going to propose a precise equation on this question, but please do so in answers / comments if you have an idea.  The most obvious metric is to simply divide upvotes / time, but that has a few downsides:   may give too much importance to new answers that get that single upvote because they showed up on the front page. It would be cool to have a coarser method with a little more statistical significance. does not take into account the "start at bottom" (number of answers) bias   Many similar metrics also take recency into account, e.g. our , Facebook  and Reddit's . Of course, I see that their need is much greater since their updates happen much more frequently than an old questions. But maybe we could take some ideas from those metrics.  Full disclosure: I might get tons of rep if this were implemented :-)


What WSDL should be given to 3rd party vendor?

We plan to integrate our salesforce instance with a 3rd party vendor via SOAP/XML.  Which version of WSDL should be given in this instance ?.  I did some reading online and it looks like there are some differences between these two WSDLs.    Enterprise WSDL is more strongly typed and the results are more predictable.  Does this mean that I should give Enterprise WSDL to this 3rd party vendor ?  Can someone let me know their inputs ?


I'm using \cite[1]{A01}. The result is     Author 2001, p. 1   The desired result is     Author 2001, 1   How do I achieve that? I'm aware of , , and  but they're not exactly my issue.  Minimal example:  \documentclass{scrartcl} \usepackage[backend=biber,style=authoryear-comp]{biblatex}  \usepackage{filecontents} \begin{filecontents}{\jobname.bib} @misc{A01,   author = {Author, A.},   year = {2001},   title = {Alpha}, } \end{filecontents}  \bibliography{\jobname.bib}  \begin{document}  \cite[1]{A01}  \end{document}


I've uninstalled Ubuntu. Yet it works and every time I switch on the computer I get to choose between windows and ubuntu. Is formatting my disk the only option I have?


updating package catch failed error while using intel graphics installer

I tried everything but this error persist continuously in Intel graphics installer for Linux   error occurred while updating the package cache.  error :  W:GPG error: https://download.01.org saucy InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY A902DDA375E52366, W:Failed to fetch cdrom://Lubuntu 13.10 _Saucy Salamander_ - Release i386 (20131016.1)/dists/saucy/main/binary-i386/Packages  Please use apt-cdrom to make this CD-ROM recognized by APT. apt-get update cannot be used to add new CD-ROMs , W:Failed to fetch cdrom://Lubuntu 13.10 _Saucy Salamander_ - Release i386 (20131016.1)/dists/saucy/multiverse/binary-i386/Packages  Please use apt-cdrom to make this CD-ROM recognized by APT. apt-get update cannot be used to add new CD-ROMs , W:Failed to fetch cdrom://Lubuntu 13.10 _Saucy Salamander_ - Release i386 (20131016.1)/dists/saucy/restricted/binary-i386/Packages  Please use apt-cdrom to make this CD-ROM recognized by APT. apt-get update cannot be used to add new CD-ROMs , W:Failed to fetch cdrom://Lubuntu 13.10 _Saucy Salamander_ - Release i386 (20131016.1)/dists/saucy/universe/binary-i386/Packages  Please use apt-cdrom to make this CD-ROM recognized by APT. apt-get update cannot be used to add new CD-ROMs , E:Some index files failed to download. They have been ignored, or old ones used instead.   I m using Lubuntu 13.10.  How can i fix this ?


How to install Genymotion on Ubuntu 14.04 LTS?

I'm using Ubuntu 14.04 LTS, 32 bits and I want to install Genymotion.  But when I go to the official Genymotion's website to download its packages, I see that there is only Genymotion 2.7.2 with support for Ubuntu 15.10 (Wily Werewolf) or above (64bit).   So do you know if there is any other Genymotion version that I can install?


I'm writing a file where I have a tikz-drawn picture in the text. Now I've tried to caption the picture, for what I used the figure environment that I saw recommended elsewhere. Unfortunately this messes up the order of the running text, i.e. now places the figure not after the example it's supposed to illustrate, but between the statement and the proof of the next theorem. How is this preventable and how can I keep my desired order.  \documentclass[12pt]{article} % use larger type; default would be 10pt  \usepackage[utf8]{inputenc} % set input encoding (not needed with XeLaTeX) \usepackage[T1]{fontenc} \usepackage[english]{babel} \usepackage{graphicx} \usepackage{amsmath,amsfonts,amssymb,amsthm} \usepackage{mathtools} \usepackage{commath} \usepackage[sc,osf]{mathpazo} \usepackage{authblk} \usepackage{calc} \usepackage{tkz-graph} \usepackage{tikz} \usepackage{amsmath,bm} \usepackage[sc,osf]{mathpazo} \usepackage{listings}             %for including python code \usepackage{color} \usepackage{xcolor} \usepackage{cite} \usepackage{hyperref} \usepackage{caption}  \usetikzlibrary{shapes.geometric}    \begin{document}     \begin{example}     For a finite field F of order $q$,...     \end{example}  \begin{figure}[h] \begin{center} \begin{tikzpicture}  \end{tikzpicture} \caption{some picture} \end{center} \end{figure} \begin{theorem}\cite[5.7.6]{bekka08} some statement \end{theorem}


Equations: Using brackets across "align" command

I have a lengthy function that is messing up:  \begin{align*} D(a,z) &= \frac{1}{\sqrt{\pi}}2^{\frac{a}{2}}e^{-\frac{z^2}{4}} \left(\cos \left(\frac{\pi a}{2}\right)\Upgamma \left(\frac{a+1}{2}\right) \ {_1F_1}\left(-\frac{a}{2};\frac{1}{2};\frac{z^2}{2}\right) \\  &+ \sqrt{2}z\sin \left(\frac{\pi a}{2}\right)\Upgamma\left(\frac{a}{2}+1\right) \ {_1F_1}\left(\frac{1}{2}-\frac{a}{2};\frac{3}{2};\frac{z^2}{2}\right) \right) \end{align*}   The last bracket \right) is not showing up. I think this is because I broke the lines in the middle at &+. Rather than splitting up the function into another set with the term right next to D(a,z)=, would it be possible to get this bracket working? I'm sure it would, I just don't know how.     Thanks!


I heard on the internet that defragmenting an SSD is quite harmful. I was wondering if it is true, and if so, why? I've already done it a few times and it didn't seems to be broken at all.


Ultra/ultimate humans, ancient structures on an alien planet, pig-people

I can't tell if I suck at Googling or am mixing up a bunch of things... My friend loaned me an audiobook a few years ago and I remember   There are parallel stories in multiple times ("fractured tandem" narrative) Sentient pigs are some characters One guy works for some ultra/ultimates(?) (post-humans of some kind)   he has a little ship and is supposed to scout worlds finds structures on some alien planet girlfriend kept hostage in some strange contraption his name is that of some religion in another time(?)    It's a part of some series.


I have added a texture to a cube in the UV editor and it shows up fine in textured view  But when I render it there is no texture  What have I done wrong?


Number of visits to each state in a Markov chain approaches the stationary distribution?

Given a finite irreducible Markov chain with transition matrix $P$ and stationary distribution $\pi$, how would you prove the following for any initial distribution vector $v$? $$\lim_{n \to \infty} \frac{v\sum\limits_{k=1}^n P^k}{n} = \pi$$ Inside the limit is the expected number of times we visit each state over the first $n$ time steps. This is a special case of the elementary renewal theorem (see ), but I'm hoping for a direct proof from the limit above. If I assume the limit exists, I can prove that it satisfies $\pi = \pi P$, but how can I prove the limit exists? A similar question was asked , but existence of the limit was not shown.


Add child pages automatically to nav menu

I have built a custom menu in Wordpress that contains links to posts and pages. I am adding it to my header using this line of code:  <?php   wp_nav_menu(     array(         'theme_location' => 'primary',          'depth'          => 0,          'menu_class'     => 'nav-menu',     )  );  ?>   My problem is, if I add a child page to the top level ones on the menu, they don't automatically appear as sublinks on the nav. I know I can create them manually each time by rebuilding the menu, but I would like to be able to just add a child page in the pages section and have it show up in the nav without having to go to the menu and build it there also, if that makes sense?  I've tried using depth => 0, but that didn't work. Is there a way to have child pages show up without having to build it into the custom menu?


Can reason defend itself without resort to reason?

I recently read, "Reason can't defend itself without resort to reason." Is this universally true?


Multiple string comparison in a single if statement shell script using OR gate

I am trying to compare the string stored in a variable with three different strings and if none of them match then throw an error. I've tried to do this in a single if statement using the logical operator OR. But every time I am getting error even though the value stored in the variable is same as one of the possible value. Please find the snippets I tried.  if [[ "$TYPE" != "LOCAL" || "$TYPE" != "REMOTE" || "$TYPE" != "BOTH" ]]; then     echo -e "\n\tINCORRECT OR NULL ARGUMENTS PASSED. PLEASE VERIFY AND CORRECT THE USAGE MENTIONED AS BELOW: \n"     Usage     exit 1 fi   if [[ "$TYPE" != "LOCAL" ]] || [["$TYPE" != "REMOTE" ]] || [["$TYPE" != "BOTH" ]]; then     echo -e "\n\tINCORRECT OR NULL ARGUMENTS PASSED. PLEASE VERIFY AND CORRECT THE USAGE MENTIONED AS BELOW: \n"     Usage     exit 1 fi


Why do we use SharePoint.client.dll and SharePoint.client.Runtime.dll

Please explain the use of SharePoint.client.dll and SharePoint.client.Runtime.dll in C# coding.


Using Label Expression with Text Formatting Tags and Ampersand

I am using a Label Expression to label a parcel layer.  The expression is:  "<FNT name=""Arial"" size=""12"">" & [Owners_Nam] & "</FNT>"   This works correctly for some labels, but any [Owners_Name] field that has an "&" in it, such as between two owners names (Smith, John & Sue), does not show up correctly.  The parcel is labeled as:  <FNT name="Arial" size="12">Smith, John & Sue</FNT>   Is there any way to solve this without removing the "&" from the [Owner Name] field?    I know how to replace the & in Field Calculator; I would just like to preserve the original field text.  I've had this same problem in the past using the <BOL> tag too.


Is there an equivalent to OSX open command in cygwin. open opens a file with the default application for that type.  I want to do something like  $ magic-command file.xls #excel opens as if file.xls would have been double-clicked  $ magic-command file.txt #notepad opens as if file.txt would have been double-clicked   You get the idea?  Basically something like a "cygwin-double-click" command.


Profesor used this property in a statistics class, first that I've seen this

$$ \sum_{i=1}^{n}\left(X_{i}-\mu\right)^{2}=\sum_{i=1}^{n}\left(X_{i}-\bar{X}\right)^{2}+n(\bar{X}-\mu)^{2} $$ My professor didn't prove this, but said it is easy to. I am confused because I can't seem to get it. Would appreciate it if someone could help. I am new to statistics, please bear with me if I make stupid statements.


How did Darth Vader plan to approach Hoth?

VADER: The Rebels are alerted to our presence. Admiral Ozzel came out of light-speed too close to the system. VEERS: He felt surprise was wiser... VADER: He is as clumsy as he is stupid. General, prepare your troops for a surface attack.  Even if Admiral Ozzel came out of light-speed at an optimal distance from the system, how did they plan to approach (land to capture Luke Skywalker) Hoth without alerting the Rebels? Also, didn't Darth Vader's ultimate plan to capture Luke Skywalker on Hoth require a surface attack anyway?


Is the harmonic oscillator potential unique in having equally spaced discrete energy levels?

I was wondering if the good old quadratic potential was the only potential with equally spaced eigenvalues. Obviously you can construct others, such as a potential that is infinite in some places and quadratic in others, but that's only trivially different. I am not referring to equally spaced as a limiting behavior either, I mean truly integer spaced.  Any ideas? If not, is there a proof for its uniqueness?  If there are other potentials with equally spaced eigenvalues, can one use them as starting points for a free-field QFT? It would be interesting to know if there is a deeper mathematical relation between all of these potentials and whether they could be used to study interacting systems.


our my document in latex the problem pf appear {paragraph ended befor \align was complete.  \par

\documentclass[14pt,english]{article} \usepackage[margin=0.8in]{geometry}  \usepackage{amsmath}  \begin{document}      \begin{align}   &=\sum_{i=1}^{n}\lambda\rho\sin(x_i-X_i)-\dfrac{1}{c}\sum_{i=1}^{n}\dfrac{-\beta_i\eta_1\sin(y_i-\beta_i X_i)+\beta_i\eta_2\cos(y_i-\beta_i X_i)}{1-\alpha_1\cos(y_i-\beta_i X_i)-\alpha_2\sin(y_i-\beta_i X_i)} \end{align} \end{document}


java.lang.NullPointerException: 'boolean java.lang.String.equals(java.lang.Object)' on a null object reference

if (chat_message.getReceiver().equals("myid")      && chat_message.getSender().equals("userid")      || chat_message.getReceiver().equals("userid")      && chat_message.getSender().equals("myid") )   I get this error? I did everything right, firebase is also right. When I enter the application, it closes immediately. Does anyone know the reason? The error I got:  java.lang.NullPointerException: Attempt to invoke virtual method 'boolean java.lang.String.equals(java.lang.Object)' on a null object reference


Is $[0,1) \cup \{2\}$ a manifold with boundary? My issue is the $2$.

This has been asked about here: , and  said      Personally I'd say $M$ wasn't a valid manifold with boundary because the $\{2\}$ doesn't have a neighborhood with any structure like an open ball/half-ball.    This is actually an exercise from An Introduction to Manifolds by Loring W. Tu and is not mentioned in an .        I have spent almost 2 hours thinking about an exercise that looked like it would take only 15 minutes and even tried pasting lemma (it's a good thing Professor Tu has solutions unlike ): The result of all that thinking is that I don't think $[0,1) \cup \{2\}$, $(\varepsilon,1) \cup \{2\}$ or $\{2\}$ is homeomorphic to any open subset of $\mathscr H^1$ or $\mathscr L^1$. I was able to show $\{0\} \subseteq \partial M$ and $(0,1)\subseteq M^0$, but I don't quite know where $2$ belongs. I believe $M$ is not locally $\mathscr H^1$. Also, I have double checked: I believe "manifold boundary" was defined for manifolds with boundary, so this isn't some trick where "manifold boundary" is actually defined for a Hausdorff and second countable space that need not be locally $\mathscr H^n$.     To generalize,     Is a half-open interval and a point not in the interval's closure a manifold with boundary?


Proof by induction Computer Science answer

Here's an attempt :     I posted needing help for this question earlier  After spending a few hours I think I may have it :P , if not close to finishing it  take(0) = 100-(2*0) = 100 therefore it holds  Assume take(k) = take(k-1)-2 holds to some point of k  prove take(k+1) = take(k)-2  take(k+1)=take(k-1)-2)-2 take(k+1) = take(k-1)-2+(-2)  take(k+1)=take(k-2)*4


If $a^\phi = 1$ then the order of $a$ divides $\phi$

How can I show that the order of an element modulo $n$ divides $\phi(n)$?  I know that if $a$ and $n$ are relatively prime, then the least positive integer $x$ such that $a^x\equiv1\pmod n$ is its order modulo $n$. I also know that, by Euler's theorem, $a^{\phi(n)}\equiv1\pmod n$. Therefore, it must be the case that $x\leq\phi(n)$.  However, all that I am left to do is to show that $kx=\phi(n)$, for some integer $k$. Do you guys have an idea on how to do this? Thanks in advance!


How to style points in QGIS based on multiple attributes

While trying to find a useful way having earthquakes displayed, I noticed that it isn't that easy to manage.  I'd like to be able to recognize the "Magnitude", "Date", and "Depth" from the style of the point. Something like:   size: based on magnitude depth: basic color (ex. <15 red, 15-30 yellow, >30 blue)  date: intensity of color as shading from 100% color to white/...   Is there a way to do so without defining dozens of rules?


Should I use HTTPS for my WordPress blog?

In general I am aware of what SSL does and how, but I'm not exactly sure as to what's the accepted custom, i.e. whether I actually am supposed to use it for my blog.  There will be no other users than me, no financial data circulating, and no truly critical information will be stored on the blog. However, I will still need to log in to the website from various places and devices.  SSL would enhance security, but could also lead to link rot in the future, is kind of a hassle, is a strain on the processor, and makes caching the website harder.  So, is it necessary to have my blog running over HTTPS? Is it a must-do in the community?


What is the application of capacitor between Vcc and GND

This is a schematic of a ATmega328P used circuit. It has paralleled two 100nF capacitors between Vcc and GND. (C8 and C9) What is the function of this two capacitors and why they are paralleled?


Changing "This question has been asked before and already has an answer." when the duplicate was posted before

From time to time, a question A is closed as a duplicate of question B, even though B was asked after A.  I find the closure message misleading:     This question has been asked before and already has an answer.   Could we change the message so that it doesn't claim A was asked after B?


How to interleave the lines of two or more files?

I have tried to get the 2 files output in a single file.  I have tried below command:  cat file1 file2   but here file2 data is appending to file1.  What I need is file1 1st line followed by file2 first line, and file1 second line followed by file2 second line etc.  Can anybody tell me how to do this in a simple way?


What is the ideal server size for an app with 1M requests per month image downloads?

Have an app with 200K+ users. Around 1M monthly requests, 20 requests per minute. Mostly for downloading images. What server size do I need? Just need an idea of RAM and Processor. There are around 10K unique images (~2MB). Storage is not a problem because 10GB is more than enough. Right now its been hosted on a Back4app Parse server but the there's a request limit and the user base is growing rapidly. Hence the need to move to other servers. Please don't suggest Firebase or other alternatives. Just need a basic idea.


One-to-many insert/upsert from landing to separate DE's

I'm bulding a preference center and having trouble with writing into two separate DE's. We have two DE's:  Newsletter_Subscribers (EmailAddress, FirstName, LastName, OptIn, Country, IPAddress, DateSubscribed, DateModified, DateUnsusbscribed)  Inserted here would be subscribers general data (only one row per subscriber).  Newsletter_Subscriber_Topics (RecordID(concat Email + TopicID), EmailAddress, TopicID, DateSubscribed, DateUnsubscribed In here would be every topic in.separate row based on a recordid.  What I'm having trouble with is to write Topics in a seperate DE row by row (PK is RecordID) - I can only get a flat insert Has anybody tried this before? Tnx.


I am attempting to get wireless working on FreeBSD 11.1 and not having much luck.  Dmesg indicates it sees the USB wireless adapter; however, ifconfig and sysctl net.wlan.devices indicate nothing.  dmesg output  Realtek 802.11ac NIC Atheros USB2.0 WLAN Atheros UB94   I tried man ath - added the entries to /boot/loader.conf, rebooted, and nothing.  Are these devices not supported or is something else going on?  From what little I know, I do not believe this to be related to this:   I do not even have /dev/ath0, if I did, I would be a little further along to getting wireless working.  The only thing I see is output in dmesg as listed.


When Dobby speaks to Harry Potter:  Dobby has heard of your greatness, sir...but never has he been asked to sit down by a wizard, like an equal.  Why does Dobby hesitate to say "I"?


As a foreword I would like to say that I am asking this question as part of a computer science course assignment, and any responses here might be referenced in my report. I am ideally looking for hints and tips to get me on the right track rather than straight up solutions.  What I am trying to get my head around is a 2 bit magnitude comparator circuit that takes in 2 sets of inputs. For example set A would contain a0 and a1, and set B would contain b0 and b1. The only output I am interested in is A > B which means the sum of all inputs in set A is bigger than set B so a0 = 1 , a1 = 1, b0 = 1, b1 = 0 would overall output a 0 and so on.  I understand how a 1 bit comparator works :     this is the most basic circuit I came up with that takes in 2 inputs and gives out an output if A > B.  However, I have been stuck for several hours trying to increase the number of inputs. My initial plan was to somehow reuse the 1 bit comparator and reuse it 3 times but every time I end up with something that ends up with an overly complicated version of the initial 1 bit circuit where the 3 inputs actually only give out 1 output and so in the end you are going in a circle and comparing 2 numbers rather than 4.  Any advice an tips on this would be very appreciated.


Modifying feature attributes of a shapefile in geotools

I have a shapefile with an attribute I want to compute programmatically in Java for each feature. I have found a lot of documentation on how to read and create shapefiles with geotools ( ), but no documentation on how to modify an attribute.  So far, I am loading the shapefile data into a FeatureCollection, and modifying each feature attribute with:  myFeature.setAttribute("ATTRIBUTE", myAttributeValue);   but these modifications are not stored into the shapefile (only in memory I guess).  Is there a way to make these modification persistent into the shapefile? Maybe there is a more standard and simple way to update feature attribute with geotools. The only thing I would like to avoid is to re-create a new shapefile.


Supposed SE is acquired and shut down, then we lose all the knowledge contained here?

The content that is being generated by SE might rival one day with that contained in Wikipedia. While I can download the Wikipedia at any point and make sure that effort is not going to be lost, I'm not sure about SE. Is there any policy covering this? (I'm confident many users have the same concern, but could not find the question formulated in any way.)


Check if current Command Prompt was launched as the Administrator

I am looking to write a script that takes user input, then makes system wide changes. I need this to be very generic, but simply put, at the top, I need it to check to see if it's being run 'As an Administrator'. If it's not, then I want to display a message to tell them that; if it is, I want it to continue on. Is there a constant way to verify this? I am not looking to start a new session as the Administrator, I just want to detect if it's currently run as admin


I am using cv.glmnet to find predictors. The setup I use is as follows:  lassoResults<-cv.glmnet(x=countDiffs,y=responseDiffs,alpha=1,nfolds=cvfold) bestlambda<-lassoResults$lambda.min  results<-predict(lassoResults,s=bestlambda,type="coefficients")  choicePred<-rownames(results)[which(results !=0)]   To make sure the results are reproducible I set.seed(1). The results are highly variable. I ran the exact same code 100 times to see how variable the results were. In the 98/100 runs had one particular predictor always selected (sometimes just on its own); other predictors were selected (co-efficient was non-zero) usually 50/100 times.  So it tells me that each time the cross-validation is running it's going to probably select a different best lambda, because of the initial randomization of the folds matter. Others have seen this problem () but there isn't a suggested solution.  I am thinking that maybe that one which shows up 98/100 is probably pretty highly correlated to all the others? The results do stabilize if I just run LOOCV ($\text{fold-size} = n$), but I am curious why they are so variable when $\text{nfold} < n$.


Gboard: Is there anyway to switch language by swiping spacebar?

I have two languages on Gboard and when I want to switch between them, I have to press the globe button. Is there anyway to switch language by swiping spacebar? I've seen this feature on Samsung Keyboard and I was wondering if it's available on the new Gboard.


Since its can be both determiner possessive pronoun and nominal possessive pronoun, an example of its as determiner possessive pronoun would be:     We saved this question for last because of its complexity.   Because complexity is a noun, so its must be a determiner possessive pronoun in this sentence. I'm looking for an example where its is used as nominal possessive pronoun in a sentence as above.


Simple series convergence/divergence: $\sum_{k=1}^{\infty}\frac{2^{k}k!}{k^{k}}$

I have the following problem: $$\sum_{k=1}^{\infty}\frac{2^{k}k!}{k^{k}}$$  I only need to find whether the series converges or diverges. My initial thinking was to use the ratio test. I hit a stump after simplifying my limit, though:  $$\lim_{k}\frac{2k^{k}(k+1)}{(k+1)^{k+1}}$$  Normally I'd just derive by L'Hopital's Rule, but the derivative is pretty long and complicated. I doubt that's the correct route.


I used a static_cast to polymorphism. I read that I should use dynamic_cast, but I can't get why. Code works in both way (with static and dynamic cast).  Could anybody show me an example with necessary dynamic_cast operator?   class Base {     public:     virtual void foo() = 0; };  class D1 : public Base {     public:     void foo()     {         std::cout << "D1()";        } };  class D2 : public Base {     public:     void foo()     {         std::cout << "D2()";        } };   int main() {     srand( time( NULL ) );     int r = std::rand()%2;      Base* b_ptr;      if(r == 0)     {         b_ptr = static_cast<Base*>(new D1);         }     else     {           b_ptr = static_cast<Base*>(new D2);        }      b_ptr->foo(); }


Can you use the Catapult Spell with Ammunition and Weapons?

Can I use the Catapult spell from the  to launch ammunition (like bolts, arrows, and sling stones) and weapons within the weight requirements? Would the damage still be bludgeoning if I used a weapon with a different damage type?  My DM does not believe that I can use this spell to temporarily substitute for my missing heavy crossbow. Since the spell says that the object launched flies in a straight line, I think things like spears, arrows and bolts should be able to deal piercing damage when launched by the spell.  I'm playing an Assassin 5, Sorcerer 4 and I plan on using this spell as part of an assassination attempt. I plan on hiding a crossbow bolt inside a long sleeve of a shirt and whistling as the Somatic component. If I did this, would it count as a surprise attack to the target, allowing me to get the automatic crit with the crossbow bolt, sneak attack damage dice, and the 3d8 piercing/bludgeoning from the spell itself?


Why are there files ending with ~ on my system?

Ive got Ubuntu desktop up and running on my N54L microserver. I've noticed however that if I'm looking at a folder on the microserver from my Windows 7 laptop, if I make a change to a file on Ubuntu and save the file, on Windows it creates a copy (or a reference) of the file but with a ~ on the end.   I can't see it on Ubuntu, only on Windows, and if I delete the original file, the ~ file remains. I can delete the ~ file at any time; it doesn't seem to make any difference to the actual file. Can anyone enlighten me as to what's going on?


How does ${!#} work in bash to get the last command-line argument?

From the Advanced Bash-Scripting Guide, to get the last command-line argument:     Or: lastarg=${!#}    This is an   indirect reference to the $# variable.    Note that lastarg=${!$#} doesn't work.


Light has momentum given by $E = pc$, which is derived from $E^2 =(m_0c^2)^2+(pc)^2$, where $m_0$ is set to zero. However I thought in this equation $p$ is defined as $p=\gamma m_0v$, which means it would also be zero if there was no rest mass. It seems like $E=pc$ is a postulate that happens to be true but isn't backed up by theory. Is there a more rigorous derivation of light's momentum? Edited out $\gamma$


Does Sultai Ascendancy interact with cards that care about surveil?

Does  interact with cards that care about surveil? Like   for instance.


Say I have a triangle with vertices defined using  \coordinate (a) at (0,0); \coordinate (b) at (1,0); \coordinate (c) at (0,1);   Let us denote by T(x,y) the triangle defined by (a),(b) and (c) which is translated by a vector (x,y). I can now easily draw T(0,0) as follows:  \draw (a) -- (b) -- (c) -- cycle;   So far so good. Now, lets say that I want to plot the triangle T(2,3). Ideally, I would like to do something like:  \begin{scope}[shift={(2,3)}]     \draw (a) -- (b) -- (c) -- cycle; \end{scope}   However, as the coordinates were defined outside of the scope the transformation (translation in this case) won't effect them. See . What would be the smart way to do it? Or more generally:  What is the best way to reuse coordinates that are defined once under varying transformations?  Possible solution: Basing on the comment of @Qrrbrbirlbel I posted an answer. This answer however, is very limited and local - is the something more general?


Has anyone actually "seen" entanglement?

I want to know if the following has been done experimentally; after the spin (or any other characteristic with a probability of 50%) of 2 entangled particles has been measured, we change the spin of one and we see the spin of the other changing instantaneously at a distance.   For example, entangled particle A is spinning up and entangled particle B is spinning down, we make A spin down and see B start spinning up at the same time.  I know entanglement has been proven experimentally but it always seems to imply this "spooky action at a distance" and I wonder if THAT has actually been proven experimentally. Maybe my question should have been has anyone seen spooky action at a distance...


error: lvalue required in while ((*arg_to)++ = (*arg_from)++);

arg_to and arg_from are of type char*   while (*(arg_to++) = *(arg_from++)); while ((*arg_to)++ = (*arg_from)++);   Why does the first expression work properly whereas the second one throws the following error:     error: lvalue required as left operand of assignment


how could I change a list of tuples with digits into a list of numbers?

I am new to Python and I am stuck in this part of coding.  I have a list looks like this: list = [(4, 7, 5), (4, 5, 7), (7, 4, 5), (7, 5, 4), (5, 4, 7), (5, 7, 4)]  and I want to change it to something looks like this:  new_list = [475,457,745,754,547,574]   how do I do that? TIA.


nZ is not ring isomorphism to mZ if n and m are 2 distinct positive integers

Is it necessary to prove this ??? Can it not be shown simply like 2Z is not ring isomorphism to 3Z , when n=2 and m=3.


irreducibility of multivariate integral polynomial

Let $f$ be a polynomial in the variables $x_1, \ldots, x_n$, where $n > 1$, and with coefficients in $\mathbb{Z}$.   Are there convenient assumptions on $f$ to make the following implication? Assume that $f$ is irreducible in the ring ${\mathbb Z}[x_1, \ldots, x_n]$, then $f$ is irreducible in $\mathbb{Q}[x_1, \ldots, x_n]$.   For instance, if $n = 1$, you would require that the leading coefficient of $f$ is equal to $1$ (Gauss lemma). Are you aware of a similar condition in case $n > 1$ ? Thank you.


Excel VBA: Can't find project or library

Running Windows 10 Microsoft Excel 16 64 bit  Just encountered this issue - Opening a normal file with a small amount of VBA coding.   On opening file today, ran into error "Can't find project or library"  Error appeared in a few files, and after restarting was localized to a single file.


How can I manually install a package on MiKTeX (Windows)

I'm new to LaTeX, investigating using it for some work projects.  I'm using MiKTeX on Windows.  My employer's locked-down network blocks the application's automatic installation function.  I can take my laptop home and successfully install from there, but if I need a package in the middle of the day I'm stuck.  I am able to access the CTAN website and download the package files (.dtx or .ins?), but I don't know what do do with them.  How can I do a manual package installation?


I have an external Western Digital Hard drive with two HFS partitions with journaling disabled.  When I connect it to a computer running Linux (Debian or Ubuntu), frequently both partitions are mounted read-only. In the past, mounting them on my Macbook and executing the command to disable the journaling often worked (even though it would tell me that journaling was already disabled) but I would love to have a solution which works every time.  Thanks!  Edit: In light of Chris Johnsen's comment below - my question is how to mount the filesystem read+write on Linux since it is not automatically doing so itself


I make environments in blender and I often have to create a new material for every single object I have in my scene. Having to make all the nodes over and over again takes much time and it's a pain. So, my question is if there is a way to create a material and make other objects inherit from it, like unreal engine, so I have only to change the textures in the nodes, and don't have to create the nodes all over again.


How to add Finder and file,edit,Go,view,windows,help thing and a search for apps thing like mac OS on top of the Ubuntu 17.10 ( Gnome ) panel

Is there any way I can get the finder and file, edit, go, view, windows, help and app search thing that mac os has on top of the panel?


Empty suggested edit by an anonymous user

I just got an  by an anonymous user in the "Suggested edits" review queue:  The edit shows no change in the Markdown or in the rendered output of the post. This can also be seen in the  (Revision 6). The suggested edit did have a very long comment, so it was not an automatic edit. I approved the edit because it really does not make a difference in this case whether it gets approved or rejected (no change in the post, no user whose edit history and reputation can be updated). How did this anonymous user get around the  for suggested edits?


Where to ask about business models or computer applications?

Specifically, I am wondering why Spotify doesn't have an option to skip explicit songs. It it too difficult to implement? Are they afraid they'll lose money if they do?  A site that covers computer applications would do. Otherwise the topic could depend on the answer - if Spotify cannot add the feature because of a programming issue, then it would fit a computer science site. If Spotify does not add the feature because of their business model, then it would fit a business site.


Why do we have "live" and "neutral" wires?

Our house wiring is AC. I thought that AC means we have current flowing from Wire 1 to Wire 2, after 1s/Frequency it flips and current flows from wire 2 to wire 1 and this goes on and on. I heard something like "Neutral has a 0V potential and only live varies between 240V and -240V" But if that's true shouldn't we have current flowing from neutral to live every 1/30 of a second?


How to find Hamiltonian from this simple Lagrangian? (tricky)

$$L~=~ \frac{1}{2} \dot{q}  \sin^2{q} $$  Is it zero or not defined?


When I plot a polar plot of $r=\sin (3 \theta)$, and $r=\sqrt{\sin (3 \theta)}$ I get nearly identical graphs, both $3$ pedal rose type plots.  In the case without the square root, it is easy to understand the plot.  However, for the plot involving the square root of $\sin 3 \theta$, it is strange to me how the graph would handle thetas for which the $\sin$ of the $3 \theta$ is negative.  It would seem that the negative values inside the square root should cause the 2 graphs to be dissimilar, yet it appears this is not the case.  Example: For $\theta = 65^\circ, r=\sin (3 \theta) = -0.259$; I would expect this it be an issue with the graph of $r= \sqrt{\sin (3 \theta)}$.  Enclosed are images of the graphs of the 2 polar plots. URL for 2 graphs -->


Found 2 liner C solution with ',' operator in for loop, can someone explain given comma operator statement?

Explanation: I've following problem statement at hand, I came across an interesting 2 liner, C solution for it under leedcode discussion section. I tried to decompose it to understand what it means, and except one small line, I understood the rest. My question is at the end. Leetcode Problem Statement: Given an array arr of positive integers sorted in a strictly increasing order, and an integer k. Find the kth positive integer that is missing from this array. Example 1: Input: arr = [2,3,4,7,11], k = 5 Output: 9  Explanation: The missing positive integers are [1,5,6,8,9,10,12,13,...].  The 5th missing >>positive integer is 9.  Example 2: Input: arr = [1,2,3,4], k = 2 Output: 6  Explanation: The missing positive integers are [5,6,7,...]. The 2nd missing positive integer is 6.  Constraints:  1 <= arr.length <= 1000 1 <= arr[i] <= 1000 1 <= k <= 1000 arr[i] < arr[j] for 1 <= i < j <= arr.length   Two liner C solution:     int findKthPositive(int* arr, int arrSize, int k){         for (int arrCurrIndex = 0, counter = 1 ; (k && (arrCurrIndex < arrSize) ? ((arr[arrCurrIndex] != counter) ? k-- : ++arrCurrIndex) : k--) || (k = counter-1, 0) ; counter++);         return k;     }   For reference: Following is a similar algorithm that's being deployed, but its just cleaner to understand.      int findKthPositive(int* arr, int arrSize, int k){          for (int counter=1, arrCurrIndex=0; counter<10000; counter++) {              // exceed arr limits              if (arrCurrIndex < arrSize) {                  if (counter == arr[arrCurrIndex]) { // found element in array                      index++;                      continue;                  }              }              // missing element              k--;              if (k==0) {                  return counter;              }          }          return 0;      }    My question: What does following line in solution #1 means exactly? (k = counter-1, 0) ======UPDATE ON ANSWER======= I modified solution #1 in question slightly to make it more readable. It highlights what is going on with the given statement in question. Here is the modified solution: int findKthPositive(int* arr, int arrSize, int k){     // move counter out of the foor loop     int counter=1;     for (int arrCurrIndex = 0;      (k && (arrCurrIndex < arrSize) ?      ((arr[arrCurrIndex] != counter) ? k-- : ++arrCurrIndex)      : k--); counter++);     return counter-1;     }


There are many waves and oscillations books out there that also include Fourier analysis but very few give the subject a thorough treatment, they just pass it in a few pages. If anybody has any sources(particularly books) that have Fourier analysis and particularly Fourier Transforms, I would appreciate if he could share his information with me.    Waves, Oscillations, Quantum Mechanics or Mathematics books are all ok if they have an intuitive Fourier analysis in them.


Scoring matrices (BLOSUM & PAM) in BLAST and other sequence-comparison programs

The  states that:      The scores are created by comparing the word in the list in step 2* with all the 3-letter words. By using the scoring matrix (substitution matrix) to score the comparison of each residue pair, there are 203 possible match scores for a 3-letter word. For example, the score obtained by comparing PQG with PEG and PQA is 15 and 12, respectively with the BLOSUM62 weighting scheme.   I do not understand how they got a score of 15 for PQG v. PEG. What is a scoring matrix, how is it computed, and how is it used?      Step 2 on that page is Make a k-letter word list of the query sequence: “Take k=3 for example, we list the words of length 3 in the query protein sequence (k is usually 11 for a DNA sequence) sequentially, until the last letter of the query sequence is included”.


Apache rewrite rule to redirect a URL with parameters to a URL without parameters

I want to go from:   www.website.com/directory/results?category=10&dir=asc   to   www.website.com/staticfile.html   I tried the following and it doesn't seem to catch:   RewriteRule "^directory\/results\?category=10&dir=asc" "\/staticfile\.html" [R, L]   I can get it to redirect using:   RewriteCond %{REQUEST_URI} "^directory\/results" [NC]  RewriteCond %{QUERY_STRING] category=10&dir=asc  RewriteRule (.*) "\/staticfile\.html"   But then it appends the parameters after html in the last example.


Generating EXE file for a java application

I have developed a stand alone Java Application which contains the following.   MySQL Installation Java Application code Tables and stored procedures Batch files VB Script files   I am planning to generate an Executable file which allows the user to install all the above with a single click. I am able to generate a Jar file but not an Exe file.   Could you please help me.  Thanks in advance.


Deleting comments in rapid succession produces improper error

SO rev. 2013.11.14.1155  I am not sure if this is on purpose or not but an incorrect error message seems to be appearing when deleting comments in rapid succession.  I have two comments:    So I deleted Comment #2 successfully and quickly went to delete Comment #1 and was greeted with this error message:


Canon EOS 4000D Hot Shoe for Sync (with Studio Flashes)

The external Flash is not showing up in the configuration Menu when using Pixel TF-321 hot shoe. Is this the wrong adapter for that camera, as there is no X connection? I want to trigger a studio flash via sync connection. Can you recommend me a working hot shoe? Thanks!


JQuery event listener not triggered when added dynically

Currently trying to dynamically toggle content within an HTML document using JQuery based upon a user click.  I have an HTML document and I have the following JQuery code, which dynamically toggles the contents of the div based upon a users click.:    $(function() {   $(".uen").on("click", uenSearch); });  function backButton () {   $(".search-form, .content-wrapper.back").toggle();   $(".uen > h3, .uen > p").toggle();   $(".uen").on("click", uenSearch); }  function uenSearch () {   $(".uen > h3, .uen > p").toggle();   $(".search-form, .content-wrapper.back").toggle();   $(".uen").off();   $("#back").on("click", backButton); }

Search by

UEN
   <form action="#" method="post" class="search-form">     <input type="text" placeholder="Enter UEN Number" name="uen_number"      required>     <button type="submit">SEARCH</button>   </form>

Back

     However, once the user has clicked on the div the first time and the content is changed, if the user tries to click on the "#back" paragraph the event listener is not triggered to toggle the div's content back to it's original.  Any help in solving this would be much appreciated.


Is it possible to classify all ideals of $\mathbb{Z}[X]$? By this I mean a preferably short enumerable list which contains every ideal exactly once, preferably specified by generators. The prime ideals are , but I'm interested in all the ideals. I couldn't find any literature about this. I don't even know the number of generators we need (Edit: Hurkyl has pointed out that any number appears!).  An ideal of $\mathbb{Z}[X]$ restricts to some ideal of $\mathbb{Z}$, say $n \mathbb{Z}$. For $n>0$ the ideal corresponds to some ideal in $\mathbb{Z}/n [X]$, and by CRT we may assume that $n$ is a prime power, say $n=p^k$. For $k=1$ we have the PID $\mathbb{F}_p[X]$, whose ideal structure is well-understood. What happens for $k=2$? The case $n=0$ seems to be even more complicated.  Since $\mathbb{Z}[X]$ is noetherian, every ideal is an intersection of primary ideals, and we should classify them first? What about other special classes of ideals, for example radical ones?  If the question is too naive in this generality, what about special cases, or slight weakenings? For example, is it possible to classify all (reduced, finite, coprimary, ...) commutative rings which are generated by a single element? This comes down to the classification of the ideals of $\mathbb{Z}[X]$ modulo isomorphic quotient rings.


Rewrite a directory to another directory without a redirect

I have the following rewrite rule:  RewriteRule ^support/(.*)$ /blog/support/$1 [R=301,NC,L]   However, all it does is a simple redirect. What I want to is for /support to show the contents of /blog/support without changing the URL from /support. How can I do this?  In addition, the above only works when /support has a trailing slash.


How do I make a border size itself depending on what it is called on?

What can I do to make it so that a border is only as wide as the p element it is applied to in CSS?  I also want to make it so that it auto-changes the size of the border if I were to change the text?   This is what it looks like without any fixing:   This is what it looks like when I manually change the size and then change the text:    I just want it to change depending on the length of the text. Thanks!


Obtain a std::ostream either from std::cout or std::ofstream(file)

how do I bind a std::ostream to either std::cout or to an std::ofstream object, depending on a certain program condition? Although this invalid for many reasons, I would like to achieve something that is semantically equivalent to the following:  std::ostream out = condition ? &std::cout : std::ofstream(filename);   I've seen some examples that are not exception-safe, such as one from :  int main(int argc, char *argv[]) {   std::ostream* fp;                                           //1   if (argc > 1)      fp = new std::ofstream(argv[1]);                         //2   else      fp = &std::cout                                          //3    *fp << "Hello world!" << std::endl;                         //4   if (fp!=&std::cout)       delete fp; }   Does anyone know a better, exception-safe solution?


storing arabic in mysql using PHP convert text to u0645u0631u062du0628u0627

I want to store arabic in mysql database but when I execute query it convert arabic to some numbers like u0645u0631u062du0628u0627  when I print this query in which $datas='hello'  insert into taxi_notification(user_id,message,datetime,type)      values(".$user_id.",'".$datas."',NOW(),'".$type."');   it converts it to   insert into taxi_notification(user_id,message,datetime,type)      values(1965,'\u0645\u0631\u062d\u0628\u0627',NOW(),'admin_notification')   I want to store Arabic string as it display in browser


Is either GET or POST more secure than the other?

When comparing an HTTP GET to an HTTP POST, what are the differences from a security perspective? Is one of the choices inherently more secure than the other? If so, why?  I realize that POST doesn't expose information on the URL, but is there any real value in that or is it just security through obscurity? Is there ever a reason that I should prefer POST when security is a concern?  Edit: Over HTTPS, POST data is encoded, but could URLs be sniffed by a 3rd party? Additionally, I am dealing with JSP; when using JSP or a similar framework, would it be fair to say the best practice is to avoid placing sensitive data in the POST or GET altogether and using server side code to handle sensitive information instead?


How is .. (dot dot) resolved in bash when cwd is a symlink to a directory

Consider the following folder structure:  . ├── test1 │   ├── nested1 │   ├── testfile11 │   └── testfile12 └── test2     ├── nested1 -> /path/to/dir/test1/nested1     └── testfile21   test2/nested1 is a symlink to the directory test1/nested1. I would expect, if it were the cwd, .. would resolve to test2. However, I have noticed this inconsistency:  $ cd test2/nested1/ $ ls .. nested1  testfile11  testfile12 $ cd .. $ ls nested1  testfile21   touch also behaves like ls, creating a file in test1.  Why does .. as an argument to cd refer to the parent of the symlink, while to (all?) others refers to the parent of the linked dir? Is there some simple way to force it to refer to paths relative to the symlink? I.e. the "opposite" of readlink?  # fictional command ls $(linkpath ..)   EDIT: Using bash


Notification for new activity goes to deleted account on https://unix.stackexchange.com/

For a while I had an account with the name .  I asked to delete that account, because my English was too broad for understanding. Now it is a little bit better and I made a new account   The notifications go to my old account. Is it possible to fix it?  No, I don't want merge the two accounts. Deleting something means for me it's gone. But if there is no other way, I'll try to merge it.


How do gravitons impact on general relativity?

As I'm reading about GR a lot lately, I was wondering: how do gravitons (if they exist ofc) impact the general relativity?  Since in GR, when we look at particles moving in space-time, we are only looking from geometric point of view so to say. Since gravity is represented with curvature of space-time via Einstein equations, we don't say gravity is a force that influences on bodies, gravity is just curvature affecting the bodies.  So if there is a graviton (gravitons) which would be mediators of gravity as a force within or not within the Standard Model, how would this be reconciled with the view of gravity as a curvature of space and time?  I would guess that this kinda question was asked by some scientists and answered, but I never really read anything on it. I don't even remember seeing gravitons mentioned in standard books about GR.  Are there any explanations about it?


How is it that no one knows who Arnold is?

We found out later in the season that Bernard is made in the image of Arnold. Also in earlier episodes, Bernard himself asks Ford about Arnold. How is it possible that no one in the whole park knows who Arnold is, and what he looked like?  I can understand that it has been many years(30?) since the park opened and new people might not know about the 2nd partner, especially since Delos will not want anyone to know about someone so important committing suicide just before opening of the park. But Elsie points out in one episode that Bernard 'has been there since ever'. I am not sure if it was mentioned or I forgot when Ford introduced Bernard in the park, but it seems a little improbable that no one even back then knew about Arnold. Also Bernard being a programmer himself could easily see at any point the code commits made by Arnold. Maybe it was one of those 'it doesn't look like anything to me' thing, maybe.  But the massacre at the church location must have been a huge thing, even if Delos hushed it up. Someone must know, right? Speaking of Delos, someone in higher management must have known about Arnold(William's father-in-law?).   On a sidenote, isn't it too cocky and careless of Ford to keep a photo of him(at a very young age) with a guy looking like Bernard in his office. Ok, so Bernard probably wont even see Arnold in that photo, but he can't be the only one visiting his office. Ford seems to spend an awful lot of time at his other underground office anyways.


Probability that exactly k bins are empty, given m balls and n bins?

I've searched for an understandable answer to this exact question and have failed to find it.  How do you find the probability that exactly $k$ bins are empty, given $m$ balls and $n$ bins? (Each ball drop is independent).  The solution to  does not explain how to find the probability that exactly $k$ bins are empty. It mentions the solution in passing in the comments, but does not thoroughly explain how to find the answer.


I would like to have Super+[ to bind to the character å, and Super+Shift+[ to bind to Å, and a few other shortcuts to type Swedish characters on the American layout. I have tried to use the Custom shortcuts menu, where I can bind xdotool key --clearmodifiers aring to Super+i, but for some reason, I cannot bind it to  Super+[. Also, binding to Super+O is also not possible. This is very strange. How can I bind shortcuts to type one (or several characters)? EDIT: The answer in  solved my issue!


Is there a way to get more than 3 mirror images from levels 1-10?

The  spell (PHB, p. 260)  grants you 3 duplicates.  (PHB, p. 205) says casting the same spell multiple times does not combine them.  Is there a low level way (under 10th level) through other class features to get more than just 3 mirror images or clone warriors?  I am aware that simulacrum can increase this but I am hoping for something lower level that I somehow missed.


TeXnic Center not interacting with Adobe Reader

Every time I do a pdf build, TeXnic center opens my Adobe Acrobat Reader DC (version 2019.010.20098), but does not actually open the document in the Reader; I have to do that manually from the File menu or from recently opened files. If my reader is already open, then TeXnic center does not build the file at all, but runs into a fatal error when I try to build. Worst of all, after each successful build, TeXnic center completely freezes for something like two full minutes, finally popping up an error message (see attached image).    Here is a picture from my TeXnic Center settings that might also be helpful to see:     This is extremely frustrating, and I would be grateful if anyone can help me troubleshoot this problem. If there is more information I need to provide, please just let me know. Thanks in advance for any help anyone is able to offer.


The factory method is used to avoid violation of Open-closed principle. Instead of creating an object by inheritage:  Product myProd = new ConcreteProduct1; // concreteProduct extends abstract product myProd.doSomething();   we use a factory "interface" with relatives concrete factories (classes that implement factory and overrride its methods):  Factory myFact = new ConcreteFact1; // (2) Product myProd = myFact.createProd();   // (1) myProd.doSomething(); // (1)   I read much about factory method; I understood that, using factory method, it's possible to exclude vilations of the open-closed principle. But I still don't understand:   with this design pattern we have still a dependency to class Product (myProd) (1) moreover.. we have a dependency with Concrete-Factories (client needs to instantiate a specific wanted concrete factory and client must know witch one) (2)   Tank you for any clarification.


Configuring Firefox to use a proxy from the command line

I'm looking for a way to tell Firefox to use a proxy in Ubuntu Ludid (10.04.1 LTS).   I'm installing Ubuntu semi-automatically on several identical machines. For this, I use a script that, amongst other things, sets system-wide proxy settings:  echo "export http_proxy=http://myproxy:3128/" > /etc/profile.d/proxy.sh echo "export HTTP_PROXY=http://myproxy:3128/" >> /etc/profile.d/proxy.sh chmod a+x /etc/profile.d/proxy.sh   I can confirm that the variables are set correctly when checking in a shell. Most programs respect this setting and use my proxy. Firefox, however, does not. When I open its network connection settings dialog, however, it is pre-set to "use system settings" for the proxy.   What does Firefox expect here? A differently-named variable? Can I set something in FF's prefs.js?


Not sure how to go about this group theory proof

Prove that if $f : G \rightarrow H$ is a group isomorphism, then for any element $x \in G$ one has $o(x) = o(f(x))$, where $o(a)$ denotes the order of the element $a$.  I feel that this proof should be online somewhere but haven't been able to find anything so would be helpful if anyone could point me in the right direction.


How can I resolve the error shown in the photo.  I have changed my desktop to gnome and managed to update but when I use this desktop my OS refuses to update.  When I update with Plasma KDE, this works.   (source: )


Prove that $F_n={n-1 \choose 0 }+{n-2 \choose 1 }+{n-3 \choose 2 }+\ldots$ where $F(n)$ is the $n$-th fibonacci number

If $F_n$ is the $n$-th fibonacci number, then prove that, $$F_n={n-1 \choose 0 }+{n-2 \choose 1 }+{n-3 \choose 2 }+\ldots$$  I tried the idea of using Pascal's triangle, but it seems to need some adjustment, so I am stuck, please help.    Any combinatorial argument would be of greater help than rigorous proof.  Thank you.


How can I determine the physical location of a Salesforce Pod/Instance?

Given a Salesforce pod/instance name such as NA3 or CS6 how can I find it's  physical location?


How is it decided/defined as to which file of an app will reside where?

most of the apps have their executables in /usr/bin and other files also in the generally defines folders..  But i found some apps keep their executeables elsewhere...Now as in linux any file can be executeable the file can actually be placed anywhere..  But for achieving proper segrigation and stuff which locations  have been defined as the ones that should be preferably be used for various files of an app?  Is there any specification for it as such?


To calculate the integral $\int_{0}^\pi e^{k \cos \theta} \cos(k \sin \theta)d\theta$

Question: let $\Gamma$ be the unit circle $\{e^{i\theta}| 0\leq \theta \leq 2\pi\}$. Calculate the integral $\int_{\Gamma} \frac{e^{kz}}{z} dz$ and hence evaluate the integral $\int_{0}^\pi e^{k \cos \theta} \cos(k \sin \theta) d\theta$.  My answer: The first one is easy to evaluate you simply look at the function $\frac{e^{kz}}{z}$ and notice that it has a simple pole at 0 and the residue is 1 so the integral is $  2\pi i$. The solution to the next part evades me. So clearly we have to convert the first integral into a form of the second but how?


Series about an enhanced man on the run from enhanced agents

Back in the 70's I read a series of books featuring an enhanced man that was on the run from mysterious greatly enhanced agents. the enhancement was via implants for the hero whereas the agents had cybernetic augmentation of the skeleton and musculoskeletal system hence their greater power. the hero and the agents were created by the same agency and his augmentation may have been a development stage.  When the hero was near an enhanced he could power up using their energy against them. One example was pushing an enhanced out of a tower block window and riding the agent down to the ground where the agent's legs pistoned through his torso, but the hero was alive.  Anyone?


If $\sum _{n=1}^{\infty \:}a_{n\:}$ converges and $\sum _{n=1}^{\infty \:}b_{n\:}$ converges.  how to proof that $\sum _{n=1}^{\infty \:}a_{n\:}-b_n$ also converges?


Get data from String and put this in a List

I want to create a List of strings in C#. These strings all come from this one:  <Functie><Titel><![CDATA[voorzitter]]></Titel></Functie><Functie><Titel><![CDATA[planner]]></Titel></Functie><Functie><Titel><![CDATA[barman1]]></Titel></Functie><Functie><Titel><![CDATA[barman2]]></Titel></Functie><Functie><Titel><![CDATA[barman3]]></Titel></Functie>   This string come from a soap respons. Here is my request:  using (Stream stream = request.GetRequestStream())         {             soapEnvelopeXml.Save(stream);         }         using (WebResponse response = request.GetResponse())         {             using (StreamReader rd = new StreamReader(response.GetResponseStream()))             {                 string soapResult = rd.ReadToEnd();                 string toBeSearched = "<tns:VoorkeurListResponse>";                 int ix = soapResult.IndexOf(toBeSearched);                  if (ix != -1)                 {                     string code = soapResult.Substring(ix + toBeSearched.Length);                     code = code.Substring(0, code.IndexOf("</tns:VoorkeurListResponse>"));                     List = code;                     System.Diagnostics.Debug.WriteLine(List);                      System.Diagnostics.Debug.WriteLine(soapResult);                 }             }         }     }   I want to get the data that is between the brackets, so my List would be: voorzitter, planner, barman1, barman2, barman3.  Could somebody help me with this problem?


why does this weird java code of only static blocks compile?

I'm getting ready for OCJP. and in one question they asked what this code will print: I thought this code would not compile. (I have never seen this syntax. I'm self taught). can someone please explain this code to me? and why does it print?  class Employee {    static int i = 10;  {       i = 15;       System.out.print(" Employee "+i);   }   static { System.out.print(" Employee static "+i); }     }  class Manager extends Employee {    static {     i = 45;     System.out.print(" Manager static ");   }{     i = 30;     System.out.print(" Manager "+i);   } }  class Owner extends Manager{   static { System.out.println("Owner"); } }  public class TestClass {       public static void main(String[] args) {       Manager m = new Manager();   }   the output:  Employee static 10 Manager static Employee 15 Manager 30


Spikes of 99% disk activity in Windows 8 Task Manager

For some reason Windows 8's Task Manager reports spikes of 99% disk activity for hours at a time. Looking at the entries in that column, however, data doesn't seem to be getting written any more quickly than when the disk activity is around 25-50% (which it seem to idle at most of the time).  Furthermore, when these 99% disk activity spikes are happening, the average response time reported in the Performance tab becomes 4000-6000ms.  Is there a good way to find out what is causing the disk activity? I've tried using Process Explorer, but I said above, the rate at which data is reportedly being written doesn't seem to correspond (Dropbox and Google Chrome are constantly the top two, but the spikes are not dependent on their being open).  Thanks in advance for any help. It gets very annoying when the computer stutters to a halt.


What is the alternative for String.contains method that is case insensitive?

While reading the line as a string from a file and string.contains("someexamplestring") will return the output of the case sensitive string.   If there is "someExampleString" in line, it's not returning.   How to identify a string in a case-insensitive manner?