If I turn an artifact into any creature for that turn that has an enter the battlefield effect, such as Vizier of the Scorpion, do I amass one? what if the artifact entered the battlefield that turn?

I was playing a game last night with a guy who was playing a new Simic Gatecrash deck, and he claimed that if he made a land into a creature, it counted as entering the battlefield, thus triggering evolve (or other "enters the battlefield" abilities).  I thought this was incorrect, being that the creature didn't actually enter the battlefield, it was just created.  Which of us was right?


Did anyone come up with an answer to this question ()?

I'm looking for a good, consistent and easy way to do a report of sudoers permissions for every user and group on the system. For users, I want the report to include permissions granted via group membership.


Given the decimal integers N and B. How can the number of digits in N! in base B be calculated without calculating the value of N!?  Example: If N = 5 and B = 2, then N! = 5! = 120. Representing the value in base B, we get 1111000 which has 7 digits.  But I'm trying to get the result without calculating the value of N!.

I am interested in good integer approximation from below and from above for binary Log(N!).  and  provides only a general idea but not exact values. In other words I need integers A and B so that  A <= Log(N!) <= B


Where to ask a question about an IDE?  It's programming related (well, kinda), but it's also a question about software. It's most likely that programmers will be able to answer the question correctly.  So, should it go on Stack Overflow, Super User or both?

There seems to be more than a few computer science/programming Stack Exchange networks (is that the correct term?). Stack Overflow, being the first, has by far the most users, questions, and answers.  What is the reasoning for creating the others, and are there clear guidelines for which kinds of questions should be posted? I can see a large amount of potential overflow, many cases of people not getting a good answer to their question, because the person who has the answer isn't browsing that particular network at the moment.  I understand that they were probably created for organizational purposes, but wouldn't it almost make more sense to just have them as categories under Stack Overflow, keep them separated but still connected, instead of making people have to create multiple 'account's, one for each network?  I am sure there was a very good reason to break them up, but as someone that is new to SE, it can be somewhat intimidating to decide which one to post in to ensure you get a good answer. For example, if I am a computer science student, my first instinct might to be to post in the computer science network, until I see that it literally has 1% of the users as the Stack Overflow network, which still seems to be for programming/computer science related questions.  So my second instinct would then to be to post it into the Stack Overflow site on the basis that I have a significantly higher chance of my question being seen and getting a good answer. Then I notice that there is also a 'programmers' network, and I don't even begin to know where that fits in. I, and I am assuming most people, will probably just post on Stack Overflow to be safe.  My question is, other than the short little description blurb of each one, is there a clear cut set of guidelines which what each network is intended for, what kinds of questions should go to each one, and is anything being done to encourage people to post in these newer, smaller (more specialized?) networks as opposed to just posting in big daddy Stack Overflow?  Now again, this is for computer science/programming/"why isn't this code doing what I want?" related questions, I am not saying that if I had a question about Linux or WordPress or something I would have the same confusion.


We are taught in schools that in English, double negatives are not so welcome, which is hard to understand because of my own language in which it is quite common.   Nevertheless, I come across some sentences which use double negatives from time to time and it's starting to cloud my mind... (e.g. : I ain't need no sleep)  And here's a new example I've just read : "I think you should set this pic as your profile picture. Not that the current one isn't nice, but this one is better."   So, is this okay to say this in this example?   Thank you very much in advance!

I am confuse with the use of 'Not that'.  When we say "Not that I like bread, but I don't like to eat more carbohydrate." It means to me that I like bread and I don't like to eat more carbohydrate. Is it correct? Or it means that I don't like bread? Please explain the meanings of these also,   Not that he is a bad boy ... Not that rain is good ... Not that I say that he is a bad boy ...


Hi guys ive got a button with jquery like this :   <html> <button id = "index.php"> </button>  </html>  <script> $('#index.php');').click(function(){ //stuff  }); </script>   however it seems that the id with a "." isnt accepted by jquery - is there a way to make it work?

Given the following classes and controller action method:  public School {   public Int32 ID { get; set; }   publig String Name { get; set; }   public Address Address { get; set; } }  public class Address {   public string Street1 { get; set; }   public string City { get; set; }   public String ZipCode { get; set; }   public String State { get; set; }   public String Country { get; set; } }  [Authorize(Roles = "SchoolEditor")] [AcceptVerbs(HttpVerbs.Post)] public SchoolResponse Edit(Int32 id, FormCollection form) {   School school = GetSchoolFromRepository(id);    UpdateModel(school, form);    return new SchoolResponse() { School = school }; }   And the following form:  <form method="post">   School: <%= Html.TextBox("Name") %>
   Street: <%= Html.TextBox("Address.Street") %>
   City:  <%= Html.TextBox("Address.City") %>
   Zip Code: <%= Html.TextBox("Address.ZipCode") %>
   Sate: <select id="Address.State"></select>
   Country: <select id="Address.Country"></select>
 </form>   I am able to update both the School instance and the Address member of the school.  This is quite nice!  Thank you ASP.NET MVC team!  However, how do I use jQuery to select the drop down list so that I can pre-fill it?  I realize that I could do this server side but there will be other dynamic elements on the page that affect the list.  The following is what I have so far, and it does not work as the selectors don't seem to match the IDs:  $(function() {   $.getJSON("/Location/GetCountryList", null, function(data) {     $("#Address.Country").fillSelect(data);   });   $("#Address.Country").change(function() {     $.getJSON("/Location/GetRegionsForCountry", { country: $(this).val() }, function(data) {       $("#Address.State").fillSelect(data);     });   }); });


i'm trying to have a template class that will call the adequate function for each Enum.  I Have 3 Enum : M_EnumA from class AAA, M_EnumB from class BBB and M_EnumC from class CCC.  My main class is like that  #pragma once  #ifndef HEADER_H_ #define HEADER_H_  #include "AAA.h" #include "BBB.h" #include "CCC.h"  template<typename T> class Header { public :    Header();    void Hello(T param);    AAA::M_EnumA retHello(AAA::M_EnumA e);   BBB::M_EnumB retHello(BBB::M_EnumB e);   CCC::M_EnumC retHello(CCC::M_EnumC e); }; #endif    template<typename T> Header<T>::Header() {   std::cout << "cst" << std::endl; }  template<typename T> void Header<T>::Hello(T param) {   std::cout << "hello" << std::endl;   std::cout << retHello(param) << std::endl; }  template<typename T> AAA::M_EnumA Header<T>::retHello(AAA::M_EnumA e) {   std::cout << "AAA" << std::endl;   return e; }  template<typename T> BBB::M_EnumB Header<T>::retHello(BBB::M_EnumB e) {   std::cout << "BBB" << std::endl;   return e; }  template<typename T> CCC::M_EnumC Header<T>::retHello(CCC::M_EnumC e) {   std::cout << "CCC" << std::endl;   return e; }   And my main is like that  int main() {   AAA::M_EnumA a = AAA::M_EnumA::A1;    Header<AAA::M_EnumA> *header = new Header<AAA::M_EnumA>();   Header<BBB::M_EnumB> *headerb = new Header<BBB::M_EnumB>();;   Header<CCC::M_EnumC> *headerc = new Header<CCC::M_EnumC>();    header->Hello(a);   headerb->Hello(BBB::A1);   headerc->Hello(CCC::A1);    return 0; }   But i got error LNK2019: unresolved external symbol in my main and i can't understand why. Sorry for this beginner question.

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


It is not really puzzling that Benjamin should have taken such authors seriously; virtually everyone – including the avant-garde – was drinking from the murky waters in the interwar period.   From the preceding paragraph it follows that Benjamin really "took such authors" (the ones with reactionary and right-wing beliefs) seriously. But does not the usage of "should have" in my sentence indicate actually the opposite?

From :      ‘We all believe, up at the Lodge, Rachael, that he will be freed from suspicion, sooner or later.’    ‘The better I know it to be so believed there, my dear,’ said Rachael, ‘and the kinder I feel it that you come away from there, purposely to comfort me, and keep me company, and be seen wi’ me when I am not yet free from all suspicion myself, the more grieved I am that I should ever have spoken those mistrusting words to the young lady. And yet I— ’   We usually use should have to say that something was not done, despite being desirable. But in this example, the mistrusting words were indeed spoken (earlier in the book). How would one explain the use of the should have construction then?   Would the following be fully equivalent to the above quote:     ‘We all believe, up at the Lodge, Rachael, that he will be freed from suspicion, sooner or later.’    ‘The better I know it to be so believed there, my dear,’ said Rachael, ‘and the kinder I feel it that you come away from there, purposely to comfort me, and keep me company, and be seen wi’ me when I am not yet free from all suspicion myself, the more grieved I am that I have spoken those mistrusting words to the young lady. And yet I— ’


I have gotten into checking my credit scores recently. I have it setup to check once a month on mint, and I also check it about once a week on credit Karma.  Today I noticed a discrepency. On my mint.com credit score (Equifax) it shows as a 738 with all of the correct details. On credit karma it shows a 792 (Equifax) and 797 (Transunion), again with all of the correct data. The credit karma was updated today, and the mint.com data updated on the 19th.  What could cause this discrepancy?

I just went to Citi Bank's website (which gives free FICO scores from Equifax for users of some credit cards) and I realized that the score I saw there was a whopping ~50 points higher than the number I saw on Mint.com, despite the fact that they both claim to have received the number from Equifax. The only difference is the fact that Mint checked my score at the end of February 2015, whereas Citi checked it at the end of January 2015.  However, nothing unusual has happened to my credit history in between these two. I can confirm on Mint's credit report that nothing seems wrong, so I'm quite confused:   What can cause such a discrepancy? Whom should I contact to understand what is going on -- Mint, Citi, Equifax, or other? How should I contact them -- file a dispute, call them, or go somewhere in person?   Note that I don't feel I'm "disputing" anything, since I don't know if there is any cause for a dispute, and hence I'm not sure it makes sense to open a dispute with Equifax. I just want to know what is going on and why two third-party agencies claim to have received such wildly different numbers from the same agencies in the span of 1 month.


If we have two topologies $(X,\mathcal{T})$ and $(Y,\mathcal{U})$, then we may take the product topology. We define the projection map $\prod_x$ in the usual way.  If $A\subset X\times Y$ is closed, is $\prod_x(A)$ closed in $X$? I think that it is, as:  $A=(X\times Y)\setminus (\cup_\lambda T_\lambda \times U_\lambda=(X\setminus \cup_\lambda T_\lambda \times Y\setminus \cup_\lambda U_\lambda)$ so that:  $\prod_x(A)=\prod_x((X\setminus \cup_\lambda T_\lambda \times Y\setminus \cup_\lambda U_\lambda)))=X\setminus \cup_\lambda T_\lambda$ which is closed in $X$. Is this correct?  Cheers.

Let $\pi: X \times Y \to X$ be the projection map where $Y$ is compact. Prove that $\pi$ is a closed map.   First I would like to see a proof of this claim.  I want to know that here why compactness is necessary or do we have any other weaker condition other than compactness for the same result to hold.


I am writing a program that generates 10k random integers in the main class and then bubble-sorts it and returns the count of how many times the array was sorted. The problem is that even though I got the method to be public and return the count, it always shows up to means 0 after running it. METHOD   public int bubbleSort(int bub[], int count){     int n = bub.length;     for(int i=0;i<n-1;i++)       for(int j=0;j<n-i-1;j++)         if(bub[j]>bub[j+1]){           int temp = bub[j];           bub[j] = bub[j+1];           bub[j+1] = temp;           count++;         }         return count;   }       void printArray(int bub[]){         int n = bub.length;         for(int i=0;i<n;i++){         System.out.print(bub[i] + " " );         }       } }  MAIN CLASS import java.util.Random; class Main{   public static void main(String args[]){     Random rd = new Random();     Bubble ob = new Bubble();     int count=0;     int[] bub = new int[10000];     for(int i=0;i<bub.length;i++){     bub[i] = rd.nextInt(100);     }     ob.bubbleSort(bub, count);     System.out.println(count);     System.out.println("sorted array");     ob.printArray(bub);    System.out.println("number of times array was sorted " + count);   } }

I always thought Java uses pass-by-reference. However, I've seen a couple of blog posts (for example, ) that claim that it isn't (the blog post says that Java uses pass-by-value). I don't think I understand the distinction they're making. What is the explanation?


Given an arbitrary group $ G $, in general does there exist a ring $ R $ with $ R^{\times} \cong G $? Or are there counterexamples of this?

Motivated by :   Which finite groups are the group of units of some ring? Which finite groups are the group of units of some finite ring? Which finite abelian groups are the group of units of some commutative ring? Which finite abelian groups are the group of units of some finite commutative ring?   It  that even for fields this is not simple to answer.  I expect the general question (Which groups are the group of units of some ring?, with no finiteness hypotheses) is even harder.


I've heard people saying "I was sure" when it comes to confirming something in the past but my friend said that it should be "I am sure" since this action is happening in the present. Are there any differences after all?

I've come across the following example sentences and I wonder why only one part of the sentence requires backshift when put into reported speech. I am familiar with the general rules as well as exceptions (still true, future ...) but I still can't come up with an explanation:  The pilot’s words were: ‘The weather was extremely bad as the plane came in to land.’  Reported speech: The pilot commented that the weather had been extremely bad as the plane came in to land.   was extremely bad -> had been extremely bad // plane came in -> plane came in  To me, both the weather and the action of the plane coming in to land are in the past.  Why don't we backshift the second part: The pilot commented that the weather had been extremely bad as the plane had come in to land.  Or, what about this one:  Barbara said, “I didn’t realise it was midnight.”  Barbara said she hadn’t realised it was midnight.  Is it okay to say: Barbara said she hadn't realised that it had been midnight.   Thank you!


I watched the video which says that electric and magnetic forces are one and the same thing it is just that when electric Field when viewed from different frame of reference becomes electric field the link for the video is given below .     My confusion is that if the two forces are same and differ only in frame of reference will there magnitude ne always same and what is the need to segregate the forces then.is there something related to newtonian mechanics which alks about forces in inertial and non inertial frame of reference

I read that force due to electric field on some particle in one reference frame can exhibit itself as force due to magnetic field in some other reference frame and that electric and magnetic fields are two aspects of same underlying electromagnetic field.   My question is what is the mechanism which can explain how an electric field becomes/creates magnetic field in some other reference frame. Is there any such explanation available in relativity theory? I am not looking for mathematics but a physical explanation.  Wikipedia article  explains something about origin of magnetic forces in a wire as a consequence of lorentz contraction and motion of electrons in the wire  Calculation of the magnitude of the force exerted by a current-carrying wire on a moving charge is equivalent to calculating the magnetic field produced by the wire. Consider again the situation shown in figures. The latter figure, showing the situation in the reference frame of the test charge, is reproduced in the figure. The positive charges in the wire, each with charge q, are at rest in this frame, while the negative charges, each with charge −q, are moving to the left with speed v. The average distance between the negative charges in this frame is length-contracted to: where is the distance between them in the lab frame. Similarly, the distance between the positive charges is not length-contracted: Both of these effects give the wire a net negative charge in the test charge frame, so that it exerts an attractive force on the test charge.  But this still does not explain origin of magnetic field in case when there are no positive charges.


Look at this code for example:   var arr = [];  var assignFunction = function() {   for (var i = 0; i < 3; i++) {     arr[i] = function() {       console.log(i);     }    } }  arr[0]; arr[1]; arr[2];   You would expect it will assign a function that you can call/run, but its not. I'm looking for good explanation what its really doing. arr[i] is typeof function, meaning it is being assigned, but will never run and print anything to console.

How would you explain JavaScript closures to someone with a knowledge of the concepts they consist of (for example functions, variables and the like), but does not understand closures themselves?  I have seen  given on Wikipedia, but unfortunately it did not help.


Please note that this is for existing URLs, not new.  I know that Google says it is recommended to have Url's to display a hyphen(-) instead of a underscore(_) in the url as a keyword seperator otherwise google views it as one phrase.  We plan to convert all our website Urls to this format.  However, the problem is that the Urls have existed for years and have a significant google ranking.   I know that the would be a dip in SEO ranking if we change them but we can obviously use 301 to reduce that.  Realistically, would it be better for our SEO if we simply kept these Url's as they are and instead use hyphens on new urls we create or would it be better to change all the existing Urls from underscores to hyphen and 301 them to their new locations?  Thank you in advance

Which is better for search engines?   example.com/my_cool_page.html example.com/my-cool-page.html  example.com/my+cool+page.html


I've been spending some time with tools like BetterTouchTool, Hammerspoon, Alfred, etc. and I've found different uses for each. However I'm having a hard time keeping everything straight, particularly tracking conflicting keyboard shortcuts between default app settings, system level commands, etc.  Is there a way to generate a complete, system-wide list of key commands that would indicate any conflicts and/or where a particular command is set?   Xcode for instance will show conflicts with system settings - is there a way to do this globally?

Is there an app / script which will listen for keyboard events and display the action that is triggered?  I use Better Touch Tool, and want to run a script on Cmd+F1 but I got the message:     The key combination "Command + F1" can't be used because it's already used by a system-wide keyboard shortcut. (If you really want to use this key combination, most shortcuts can be changed in the Keyboard & Mouse panel in System Preferences.)   I couldn't find the triggered action until I did a text search on , and now I'm curious!   In Sublime Text, it's possible to open Sublime's python terminal and sublime.log_commands(True) to log commands triggered as the keys are pressed… is there something similar for system wide key events?


I know that if you have a non-arithmetic or geometric progression, you can find a sum $S$ of a series with the formula $S=f(n+1)-f(1)$ where the term $u_n$ is $u_n=f(n+1)-f(n)$. Then you can prove that with induction. What I don't understand is how I should go about finding the function $f(n)$. For example if I want to calculate the sum to $n$ terms of the series $1^2 + 2^2 + 3^2 +  ... + n^2$ then, according to my textbook, my $f(n)$ function should be a polynomial with degree one more than the degree of a term in my sequence - so because the $n$th term in the sequence is $P(n)=n^2$ then the function $f(n)$ should be $f(n)=an^3+bn^2+cn+d$. But how did they know that it should look like that and how do I gain some intuition into finding that function to help me solve similar problems in the future?

why is $\sum\limits_{k=1}^{n} k^m$ a polynomial with degree $m+1$  in $n$?  I know this is well-known. But how to prove it rigorously? Even mathematical induction does not seem so straight-forward.  Thanks.


I've got the following code snippet: class Base{  public:   virtual float operator()(float x){return x;}; };  class Child: public Base{  public:   virtual float operator()(float x) override{return 2 * x;}; };  void scoped(Base b){     std::cout << "Nested: " << b(5) << "\n"; }  int main() {     Child c = Child();     std::cout << "Output: " << c(10) << std::endl ;     scoped(c); }  The output 20  // expected 5  // unexpected. Should ahve been doubled?  context I'm making scoped take a base class because I've got multiple child classes derived from it. On one hand I suppose it makes sense that it would called the () from the base class since that's what the type is declared as. On the other hand, why wouldn't it call the method from the instance (which is a Child first, then a Base?) Questions  Am I missing something? How would I accomplish what I'm aiming to do? I get the feeling that templates may be a solution but maybe are not the right one?  Why is it calling the base class method as opposed to the child

Someone mentioned it in the IRC as the slicing problem.


Until now, I've only seen credit card charges displayed on the POS terminal under a country's own currency.  However, in Peru, many terminals display both the local soles and my card's usual currency, Canadian Dollars and the vendor asks me which currency I would prefer to pay in, which I can pick.  Now, until this trip, I had come to expect that credit card companies will profit handsomely at my expense by extra charges and perhaps a less than ideal exchange rate.  I assume this is still the case.  My question in this case is, will those charges, and the final cost to me, be less if I pay in local soles or if I pay in CAD $?  Are the displayed CAD/Soles amount, and therefore an implicit exchange rate, telling me the whole story?  Assume, if you're not sure about CAD $ specifics, that the choice is between USD $ or soles.  Also fine if you have experience with a similar system of currency payment choices in a country other than Peru, I assume credit cards operate relatively similarly across countries.  But I am really looking for people who went through it and did the math upon their return.  In other words - better to pay in soles / better to pay in dollars / about the same?  Note:  the vendor is not the one offering me a choice between say 70 soles or 25 CAD and therefore setting the exchange rate, at that point they don't even know where I come from.  Its the VISA terminal itself that recognizes my card.  So, whatever the merits or not of paying in local currency, that is NOT driven by the vendor's choice of exchange rate (which, yes, I would assume would be worse than VISA's).

Whenever I shop at airports abroad, I always get asked to choose between the currency options while paying via my credit card.  One is the local currency and another one is the currency of the country where the card is issued in[India(INR) in my case].  Why are there two options? And what are the benefits of choosing one over the other?


I am getting this error at runtime.     java.lang.RuntimeException: Unable to start activity ComponentInfo   java.lang.NullPointerException: Attempt to invoke virtual method   'boolean java.lang.String.equalsIgnoreCase(java.lang.String)' on a   null object reference   StackTrace:  01-12 03:44:54.270: E/AndroidRuntime(1437): FATAL EXCEPTION: main 01-12 03:44:54.270: E/AndroidRuntime(1437): Process: home.saket, PID: 1437 01-12 03:44:54.270: E/AndroidRuntime(1437): java.lang.RuntimeException: Unable to start activity ComponentInfo{home.saket/home.saket.addmember.Add_Update_User}: java.lang.NullPointerException: Attempt to invoke virtual method 'boolean java.lang.String.equalsIgnoreCase(java.lang.String)' on a null object reference 01-12 03:44:54.270: E/AndroidRuntime(1437):     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2298) 01-12 03:44:54.270: E/AndroidRuntime(1437):     at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2360) 01-12 03:44:54.270: E/AndroidRuntime(1437):     at android.app.ActivityThread.access$800(ActivityThread.java:144) 01-12 03:44:54.270: E/AndroidRuntime(1437):     at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1278) 01-12 03:44:54.270: E/AndroidRuntime(1437):     at android.os.Handler.dispatchMessage(Handler.java:102) 01-12 03:44:54.270: E/AndroidRuntime(1437):     at android.os.Looper.loop(Looper.java:135) 01-12 03:44:54.270: E/AndroidRuntime(1437):     at android.app.ActivityThread.main(ActivityThread.java:5221) 01-12 03:44:54.270: E/AndroidRuntime(1437):     at java.lang.reflect.Method.invoke(Native Method) 01-12 03:44:54.270: E/AndroidRuntime(1437):     at java.lang.reflect.Method.invoke(Method.java:372) 01-12 03:44:54.270: E/AndroidRuntime(1437):     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:899) 01-12 03:44:54.270: E/AndroidRuntime(1437):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:694) 01-12 03:44:54.270: E/AndroidRuntime(1437): Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'boolean java.lang.String.equalsIgnoreCase(java.lang.String)' on a null object reference 01-12 03:44:54.270: E/AndroidRuntime(1437):     at home.saket.addmember.Add_Update_User.onCreate(Add_Update_User.java:38) 01-12 03:44:54.270: E/AndroidRuntime(1437):     at android.app.Activity.performCreate(Activity.java:5933) 01-12 03:44:54.270: E/AndroidRuntime(1437):     at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1105) 01-12 03:44:54.270: E/AndroidRuntime(1437):     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2251) 01-12 03:44:54.270: E/AndroidRuntime(1437):     ... 10 more 01-12 03:44:54.272: W/ActivityManager(472):   Force finishing activity home.saket/.addmember.Add_Update_User 01-12 03:44:54.273: E/ActivityManager(472): Invalid thumbnail dimensions: 384x384   Below I am posted the codes and pointed out the error line.  Add_Update_User.java:  @Override     protected void onCreate(Bundle savedInstanceState) {     // TODO Auto-generated method stub     super.onCreate(savedInstanceState);     setContentView(R.layout.add_update_screen);      // set screen     Set_Add_Update_Screen();      // set visibility of view as per calling activity     String called_from = getIntent().getStringExtra("called");      if (called_from.equalsIgnoreCase("add")) {  --->38th error line         add_view.setVisibility(View.VISIBLE);         update_view.setVisibility(View.GONE);     } else {          update_view.setVisibility(View.VISIBLE);         add_view.setVisibility(View.GONE);         USER_ID = Integer.parseInt(getIntent().getStringExtra("USER_ID"));          Contact c = dbHandler.Get_Contact(USER_ID);            add_name.setText(c.getName());         add_mobile.setText(c.getPhoneNumber());         add_email.setText(c.getEmail());         // dbHandler.close();     }     }

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


I have problem with my code below, here is the error:     Exception in thread "main" java.lang.NullPointerException     at   javaPractice.Difference.computeDifference(Difference.java:24)     at   javaPractice.diffSolution.main(diffSolution.java:18)   class Difference {      private int[] elements;     public int maximumDifference;      public Difference(int[] a) {         this.elements = a;     }      List<Integer> maximumDifferenceList;      public void computeDifference() {         for(int i = 0; i < elements.length; i++) {             for(int j = 0; j < elements.length; j++) {                 if(i != j) {                     maximumDifferenceList.add(Math.abs(elements[i] - elements[j]));                 }             }         }         Collections.sort(maximumDifferenceList);         maximumDifference = (int) Collections.max(maximumDifferenceList);     }  }  public class diffSolution {      public static void main(String[] args) {         Scanner sc = new Scanner(System.in);         int n = sc.nextInt();         int[] a = new int[n];         for (int i = 0; i < n; i++) {             a[i] = sc.nextInt();         }         sc.close();          Difference difference = new Difference(a);          difference.computeDifference();          System.out.print(difference.maximumDifference);     }  }   I tried to print out elements array, it seems to have values but it does not evaluate the line below:     maximumDifferenceList.add(Math.abs(elements[i] - elements[j]));   Thank you in advanced!


I have a pagereference for which I want to write a test class but get the error  Expected: System.PageReference[/CustomLoginPage], Actual: System.PageReference[/CustomLoginPage]. What am I doing wrong:  Class      /**  * An apex page controller that exposes the site login functionality  */ global with sharing class CommunitiesLoginController {      global CommunitiesLoginController () {}      // Code we will invoke on page load.     global PageReference forwardToAuthPage() {         String startUrl = System.currentPageReference().getParameters().get('startURL');         String displayType = System.currentPageReference().getParameters().get('display');         return Network.forwardToAuthPage(startUrl, displayType);     }     // Code we will invoke on page load.     global PageReference forwardToCustomAuthPage() {         return new PageReference('/CustomLoginPage');     } }   Testclass      /**  * An apex page controller that exposes the site login functionality  */ @IsTest global with sharing class CommunitiesLoginControllerTest {     @IsTest(SeeAllData=true)      global static void testCommunitiesLoginController () {         CommunitiesLoginController controller = new CommunitiesLoginController();         System.assertEquals(null, controller.forwardToAuthPage());           PageReference p = new PageReference ('/CustomLoginPage');         System.assertEquals( p, controller.forwardToCustomAuthPage());        }  }

In my page constructor I call a method isFirstPageLoaded, to  check if the loaded page is the first page of the wizard.   private final PageReference FIRSTPAGE = Page.Maintenance_Lock_1;   private void isFirstPageLoaded() {          if(ApexPages.currentPage()!=this.FIRSTPAGE) {              throw new MaintenanceLockException(this.FIRSTPAGE + ' --- ' + ApexPages.currentPage());          }      }   The problem is: Even if I open the first page of the wizard, the exception is thrown. How can I compare two PageReferences? I would like to avoid to parse the URLs and remove parameters etc...


I saw somewhere that the above integral is equal to $\pi/4$ for all real number $m$.  This seems to be surprising. Does anyone have a nice proof?

Let $a$ be a non-zero real number. Is it true that the value of $$\int\limits_0^\infty \frac{\mathrm{d} x}{(1+x^2)(1+x^a)}$$  is independent on $a$?


I can use AutoHotKey to replace some simple math characters to Unicode characters. For example, :*:L2::L² will replace L2 to L² automatically. But then I have to define another :*:S2::S² just to write S². Even a generic :*:^2::² is not ultimate since there are not only numbers, but letters, not only superscripts, but overscripts. In short, I want to have a systematic method to use  at once.  Do you have any suggestion?

Often, during a conversation or an email, or at a forum, I would like to type some math, but I don't need full equation support. Unicode symbols should suffice.  What I need is an easy way to type math-related Unicode symbols. Since I already know LaTeX, it makes sense to use the LaTeX symbol mnemonics to type the math symbols.  What I currently did is to write an AutoHotkey script which automatically replaces LaTeX symbol names preceded by \ with the corresponding Unicode symbol, using the hotstring AutoHotkey feature. However, the AutoHotkey hotstrings proved unstable for many strings. Having a couple of tens lines would cause AHK to fail recognizing the strings from time to time.  Any other solution? (No, Alt+(Unicode number) isn't convenient enough.)  Attached is my AHK script. The PutUni function is taken from .  ::\infty:: PutUni("e2889e") return ::\sum:: PutUni("e28891") return ::\int:: PutUni("e288ab") return ::\pm:: PutUni("c2b1") return ::\alpha:: PutUni("c991") return ::\beta:: PutUni("c992") return ::\phi:: PutUni("c9b8") return ::\delta:: PutUni("ceb4") return ::\pi:: PutUni("cf80") return ::\omega:: PutUni("cf89") return ::\in:: PutUni("e28888") return ::\notin:: PutUni("e28889") return ::\iff:: PutUni("e28794") return ::\leq:: PutUni("e289a4") return ::\geq:: PutUni("e289a5") return ::\sqrt:: PutUni("e2889a") return ::\neq:: PutUni("e289a0") return ::\subset:: PutUni("e28a82") return ::\nsubset:: PutUni("e28a84") return ::\nsubseteq:: PutUni("e28a88") return ::\subseteq:: PutUni("e28a86") return ::\prod:: PutUni("e2888f") return ::\N:: PutUni("e28495") return


I am new to this site.  While browsing questions, I've found some to be very interesting.  Can anyone tell me how to track those questions?

What does bookmarking a question mean? How do you bookmark a question? Do users get updates on their bookmarked questions? Are my bookmarks publicly visible? How do you see your own bookmarks? How do you see other users' bookmarks? How do you see which users have bookmarked a particular question? What impact does the bookmark system have on the voting system? Can I "un-bookmark" a question? Can I search within my bookmarks?


I am making a Rubik's cube program. That will simulate a Rubik's cube. I am having problems with gimbal lock. I need to know how to avoid it. To my understanding I can either multiply the x, y, z rotation matrices in a specific order to acquire the rotation I am trying to get. Or I can use a quaternion which is like rotating around a single user defined axis instead of the axis x, y, or z. I can't really understand visually how I can get the resulting axis from two other axis. (x, y, z) How can I get the resulting axis for my quaternion from my Euler rotations? Will it just result in gimbal lock again?  One of the big problems is. I don't know what rotations are going to be made. I need to make it general purpose.  Edit: Little bit more documentation of my problem:  My Euler matrix multiplication looks like this      rotate = XMMatrixRotationX(content.mesh[meshToRotate[i]].rotation.x) * XMMatrixRotationY(content.mesh[meshToRotate[i]].rotation.y) * XMMatrixRotationZ(radians);     content.mesh[meshToRotate[i]].rotation.z = radians;   As a gimbal lock would suggest the last axis in the rotation gets the problem. When you attempt to rotate the front or back face you get problems.

I am trying to write code with rotates an object.  I implemented it as:  Rotation about X-axis is given by the amount of change in y coordinates of a mouse and  Rotation about Y-axis is given by the amount of change in x coordinates of a mouse.  This method is simple and work fine until on the the axis coincides with Z-axis, in short a gimble lock occurs.  How can I utilize the rotation arount Z-axis to avoid gimbal lock.


Linux users! I'm having a issue:  I have all pdf files in directoryDownloads, but I want it to copy all the files in subfolder \Download\BOOKS\. How would I copy all files with for loop?  for files in ...

I want a command that allows to select specific files based on their extensions to move them to another directory.


Beverages of any type generally contain some measure of water. However, in the case of some liquids, the non-water components take more water from the human body to filter out than the water contained in the beverage.  The most-known example of this is salt-water from the ocean - there is too much salt so the body tries to use water from the body to "water down" the salt water.    Given a beverage with unknown additives, how would one determine if the beverage would actually hydrate or dehydrate a person?  If you knew the ingredients (and the amounts), could you tell that way?  Edit:comments seem to indicate that it depends on the solutes and tonicity of the solution: are there any other factors to be aware of? What (common) solutes will have the largest affect on whether the human body will be hydrated and why?  if you need "common" to be defined, consider it defined as: contained in many[more than 3] store-bought beverages

If water has a low salt content, it hydrates us. When water has too high salt concentration, like sea water, it drains water out of us instead when we drink it. At what salt concentration would water leave us completely unaffected?


I can't resize my NTFS partition named My Folder to join the unallocated space for some reasons I can't get.

Previously, I have installed Windows 7 on my 320 GB laptop with three partitions 173, 84 and 63 GB each. The 63 GB partition was where the Windows was installed. The rest were for file containers.  Now I changed my OS to Ubuntu 12.04 LTS. I installed Ubuntu by replacing the entire Windows 7 on the 63 GB partition. The rest of the partitions remain as an NTFS Windows partition and I can still access them both (the 173 and 84 GB partitions).  Now I want to change the two partitions of Windows into an Ubuntu format partitions plus most importantly, I want to extend the 63 GB partition to more than a 100 GB because at the moment I am running out of disk space. Whenever I try to install any application, especially using wine, it always complains for a shortage of disk space.  How do I do the extending activity before I entirely format my laptop again and lose all the important files on my partitions?


Prove that any two consecutive terms of the Fibonacci sequence are relatively prime.   My attempt:    We have $f_1 = 1, f_2 = 1, f_3 = 2, \dots$, so obviously $\gcd(f_1, f_2) = 1$. Suppose that $\gcd(f_n, f_{n+1}) = 1$; we will show that $\gcd(f_{n+1}, f_{n+2}) = 1$. Consider $\gcd(f_{n+1}, f_{n+2}) = \gcd(f_{n+1}, f_{n+1} + f_n)$ because $f_{n+2} = f_{n+1} + f_n.$ Then $\gcd(f_{n+1}, f_{n+1} + f_n) = \gcd(f_{n+1}, f_{n}) = 1$ (gcd property).  Hence, $\gcd(f_n, f_{n+1}) = 1$ for all $n > 0$.  Am I on the right track? Any feedback would be greatly appreciated.  Thanks,


Something funky has been happening since the Stack Exchange app was updated on my iPhone: every time I write a comment, I get a success message, but the question goes blank and can’t interact with it.  Screenshots of the problem:        The solution/workaround to the problem is simple: exit the question (the top bar is still there) and get back in, and everything will load fine (including the comment I wrote).  Is that something happening to more people, or is it only my iPhone? (6S for more detail.)

Since iOS 11.2 all the way through 12.2 beta 4, if you post or discard a comment on any post on any SE community, the screen will turn white. This has been ongoing continuously for a year now, and it affects both the SE app and the SO app.   You can go back to the previous screen and open the question again, and everything appears as normal. You can also rotate the screen to get the text to come back. Using the arrows to navigate between the question and answers updates the HUD, but the screen remains white unless one of the above is done to get the text back.        UPDATE: After posting anything (comment, answer), the screen goes all white except for the sidebar. Perhaps it is intentional, but I prefer last week’s behavior of going back to the content. Not major, since the sidebar icons still work.


I am writing an script to dump my history log into another file "myhistory.log", and then clear that history. I have written the following set of commands:  date >> myhistory.log  history >> myhistory.log  history -c   Everything goes well except that the previous history is not cleared. I have tried the following variations:   \history -c   and  CLRH="history -c" exec $CLRH   What I am missing probably??

I want to clear all previous commands from the history of my server. I used history -c and it seems all things are cleared but when I ssh to the server, all the commands are still there.  How can I clear them permanently?


Is it possible, that one of my slide in beamer is  11 pt    and I want 10 pt font in other slide?

I want to create a TeX document for which the first (summary) page is \documentclass[10pt]{article}, but for which the rest of the document is \documentclass[12pt]{article}. Is there an easy way to do this?


I'm fairly new to C# threading, so apologies in advance for this newbie error. The aim of the following code is to evaluate the fitness of a population that is stored in an array called members. The procedure members.calculateFitness() is a black box (i.e. I can't modify it to improve performance), so I'm trying to setup threads that call the black box simultaneously, and each thread will deal with 1/THREAD_COUNT population members (so if THREAD_COUNT=4, each thread will deal with 1/4 of the population).  In the first for loop I initialise each thread. In the second for loop, I start the thread.   public void ThreadedPrintPopFitness ()     {         int THREAD_COUNT = 1;         int membersPerThread = members.Length / THREAD_COUNT;          Thread[] fitnessCalculator = new Thread[THREAD_COUNT];         int[] threadResult = new int[THREAD_COUNT];          for (int i = 0; i < THREAD_COUNT; i++) {             int start = i * membersPerThread;             int stop = (i+1) * membersPerThread;             fitnessCalculator [i] = new Thread (() => getMaxFitness (members, start, stop, ref threadResult [i]));         }          for (int i = 0; i < THREAD_COUNT; i++) {             fitnessCalculator [i].Start ();         }          for (int i = 0; i < THREAD_COUNT; i++) {             fitnessCalculator [i].Join ();         }          int maxFitness = 0;         for (int i = 0; i < THREAD_COUNT; i++) {             if (maxFitness < threadResult [i])                 maxFitness = threadResult [i];         }          Console.WriteLine ("(ThreadedCount) Fittest Population Member's Fitness: " + maxFitness);     }      private static void getMaxFitness (PopulationMember[] members, int start, int stop, ref int result)     {         int maxFitness = 0;          for (int i = start; i < stop && i < members.Length; i++) {             if (members [i].calculateFitness () > maxFitness) {                 maxFitness = members [i].lastFitness;             }         }          result = maxFitness;     }   Stepping through the code shows that it gets into the second for loop, and then jumps back to the first for loop and declares an IndexOutOfBoundsException on the integer i. I can see that i = THREAD_COUNT (I've tried with different numbers for THREAD_COUNT).  I'm completely baffled, what am I doing wrong? Thanks in advance!

I met an interesting issue about C#. I have code like below.  List<Func<int>> actions = new List<Func<int>>();  int variable = 0; while (variable < 5) {     actions.Add(() => variable * 2);     ++ variable; }  foreach (var act in actions) {     Console.WriteLine(act.Invoke()); }   I expect it to output 0, 2, 4, 6, 8. However, it actually outputs five 10s.  It seems that it is due to all actions referring to one captured variable. As a result, when they get invoked, they all have same output.  Is there a way to work round this limit to have each action instance have its own captured variable?


I am editing this question since it was marked duplicate as another question about how to kill a zombie process.  I am not looking for an answer to how to kill a zombie process. I do not have zombies on my system and I am aware of how zombies are created.  Let me try to re-phrase the question. Presently, these are the accepted methods of removing a zombie:   Sending SIGCHLD to the parent. Works theoretically, not always in practice since one of the reasons the zombie was created in the first place could be because the parent wasn't responding properly to SIGCHLD. Killing the parent process. Fixing the bug in the program that created the Zombie. Rebooting. Or as mentioned at  Or for this reason mentioned by @richard in the comments to my question before this edit:    ..to prevent the pid being reused. The parent has the pid of the child and may signal the child (may try to kill it), just from the pid it recieved when it created the child. It would be bad for the pid to be reused. Therefore the child remains in a zombie state until the parent acknowledges the death of the child, or the parent dies.   Now my questions are:   Why is that there is no straight-forward and direct method to clean up a zombie or zombies.  What would be the side-effects/consequences if zombie could've been killed with a signal. What is stopping the *NIX maitainers to create a SIGNAL or a command (my apologies, if the phrase 'creating a new signal' is not technologically acceptable) that cleans up a zombie.

Transmission is intermittently hanging on my NAS.  If I send SIGTERM, it doesn't disappear from the process list and a <defunct> label appears next to it.  If I send a SIGKILL, it still doesn't disappear and I can't terminate the parent because the parent is init.  The only way I can get rid of the process and restart Transmission is to reboot.  I realize the best thing I can do is try and fix Transmission (and I've tried), but I'm a novice at compiling and I wanted to make sure my torrents finished before I start messing around with it.


One thing I know about the Vernam cipher is that the key must not be repeated over the plain-text, for example:  Plain-text (hex):   48 65 6C 6C 6F 57 6F 72 6C 64 // HelloWorld One-time-pad (hex): 47 72 61 70 65 47 72 61 70 65 // GrapeGrape Cipher-text (hex):  15 23 13 28 10 16 29 19 28 01 // ??????????   Notice that in the one-time-pad, the sequence 47 72 61 70 65 is repeated.  How does this constitute a vulnerability, and how can the one-time-pad be discovered through its repetition?  Side-note: I'd be especially interested to know how it would be possible to determine a single repeated byte pad, for example:  Plain-text (hex):   48 65 6C 6C 6F 57 6F 72 6C 64 // HelloWorld One-time-pad (hex): 56 56 56 56 56 56 56 56 56 56 // VVVVVVVVVV Cipher-text (hex):  1E-33-3A-3A-39-01-39-24-3A-32 // ??????????

My question might appear the same as the question , but actually I did read all the answers and none of them helped me with the details I need.  I am new to cryptography and my problem is with two time pad attacks on OTP. The problem I had in my course was that I have 10 ciphertexts encrypted with the same key $K$. I am then given another ciphertext that I should decrypt.  I know that XOR-ing two ciphers gives me the XOR of their original messages.  My question is what is the correct thing to do after that?  I tried to take 3 ciphertexts $C_1, C_2$ and $C_3$.  Then get $S_1 = C_1 \oplus C_2  \oplus $' ', also get $S_2 = C_1 \oplus C_3 \oplus$ ' '.  After that I compared all corresponding characters in $S_1$ and $S_2$,  and if $S_1[i] = S_2[i]$ then I calculate $S_1[i] \oplus C_2[i]$ to get $K[i]$.  I tried this on paper before coding and it worked, but I might be missing something.  Is this the right approach? Why does it work?


As you found out I am relatively new to XeTeX and I want to import bibliography to my academic essay. But I have a few questions on how to do that:   Should I record Bibliography in separate file or define it on the same tex file? If I define it over a separate file, how XeTeX will find out the bibliographic references?

I just started LaTeX, so I have a very vague idea how to operate it. I am now trying to make a bibliography. From what I understood, I need a .bib document, which I then will insert with \bibliography{}. My question is, how can I make a .bib file? I have an OpenOffice document that I'd like to use. Browsing a bit on the internet, there seems to exist a possibility to convert .bib files into other types, but I haven't found the right conversion. On bibtex.org the converter is disabled.  I have a feeling I'm doing something very wrong, can someone please help?


The area of a circle is $\pi r^2$ if you increase $r$ the area will increase by the square so if this area was of energy and you increase the area it is dispersed you would expect its energy to weaken by the square. Is this the intuition behind gravity weakening be the square of the distance?

Is there an intuitive explanation why it is plausible that the gravitational force which acts between two point masses is proportional to the inverse square of the distance $r$ between the masses (and not only to the inverse of $r$)?


I want to have a macro that behaves differently based on the context. Assume I write a tutorial in X language. A term that I use must be written in X language followed by the corresponding English translation (enclosed and italicized in ()) only when it occurs at the first time. The remaining occurrence will only be written in X language.   I can do it with the following code.  \newif\ifVector \newcommand{\Vector}{%     \ifVector         vektor%     \else         vektor (\textit{vector})%         \Vectortrue     \fi}   But a new problem arises. How to make the macro change its capitalization when it appears in the beginning of a sentence? Here is my complete dummy code for you.  \documentclass[preview,border=12pt]{standalone}  \newif\ifVector \newcommand{\Vector}{%     \ifVector         vektor%     \else         vektor (\textit{vector})%         \Vectortrue     \fi}   \begin{document} \Vector\space isg kush guste vien. Fur sji nam von gis ta marjo navar \Vector. \Vector\space is fin nom bis kan da dej vanm. \end{document}

Is it possible to make macros give different results at the beginning of a new sentence? Suppose that I want the macro "\secname" to write "Section" at the beginning of a new sentence, and "section" anywhere else. How can I do so?


I've created a .com personal website where I intend to describe my research, including full-text PDF copies of my published papers. I was going to also make these PDFs available in my account on academic social-networking websites such as ResearchGate and Academia.edu. I've seen many researchers do the same, and indeed these websites will happily accept anything you will upload. However, I have doubts whether this would actually be legal. Most of my papers are not open-source, and without a subscription, one would just hit the journal's paywall. Is it likely that if I upload these PDFs, I am inviting copyright infringement allegations from the publishers, or any other sort of legal problem? My field, if relevant, is experimental psychology. Having researched this question on this SE site as well as some of the above-stated ones, I found no conclusive answer. Various proposed alternatives to the uploading of full-text PDFs seem to be to either upload preprints or personal "accepted" (but not journal-formatted) versions, or to state (both on the personal website and on academia.edu etc) that full-text PDFs are available upon individual reasonable request. However, none of these options seem ideal, when you'd simply like whoever is interested in your papers to be able to quickly access them in the obvious places.

Is it legal to upload a PDF of my non-open-access papers to research networks, such as ResearchGATE and Academia.edu?    I am pretty sure that it could cause some problems, because normally people should buy them from the publisher. But I have seen many researchers put the PDF of their (non-open access) papers for free there so as to get more citations.


I need to calculate the time complexity of the following code:  for (i = 1; i <= n; i++) {   for(j = 1; j <= i; j++)   {    // Some code   } }   Is it O(n^2)?


One of the most popular answers to one of the most popular questions in Java here reads:      Java is always pass-by-value. The difficult thing to understand is that Java passes objects as references and those references are passed by value.   So what does "Java passes objects as references and those references are passed by value." mean?   Does it mean that:  The memory location to which the original variable points is copied as the value of the new temporary variable? (if this is the case, all the changes made inside the function will be reflected in the original, right?)  If not, what does it mean?

I always thought Java uses pass-by-reference. However, I've seen a couple of blog posts (for example, ) that claim that it isn't (the blog post says that Java uses pass-by-value). I don't think I understand the distinction they're making. What is the explanation?


Show that the equation,  $x^3+10x^2−100x+1729=0$ has at least one complex root $z$ such that $|z|>12$.

Show that the equation,     $x^3+10x^2-100x+1729=0$ has at least one complex root $z$ such that $|z|>12.$


Evaluating $\displaystyle \int_{0}^{2\pi}\frac{1}{4\cos^2 t + 9\sin^2 t} dt$   Can someone show me a way using Complex Analysis methods? This is what I tried:    Let $C$ be the contour defined by $C(t)= 2\cos t + 3i\sin t$, $0 \leq t \leq 2\pi$.    Considering the integral    $$I= \int_{C}\frac{dz}{z}= 2\pi i$$ by Cauchy's Integral Formula, then also $$I = \int_{C}\frac{\overline{z}}{|z|^2}= \int_{0}^{2\pi}\frac{2\cos t - 3i\sin t}{4\cos^2 t + 9\sin^2 t}\cdot (-2\sin t + 3i\cos t) dt\\ = \int_{0}^{2\pi} \frac{5\sin t\cos t + 6i}{4\cos^2 t+ 9\sin^2 t}dt = 2\pi i.$$ I'm not sure where to go from here.

closed form of $$\int_{0}^{2\pi}\frac{dx}{(a^2\cos^2x+b^2\sin^2x)^n}$$  for $a,b>0$  n=1 we get  $$\int_{0}^{2\pi}\frac{dx}{(a^2\cos^2x+b^2\sin^2x)^1}=\frac{2\pi}{ab}$$  n=2 we get  $$\int_{0}^{2\pi}\frac{dx}{(a^2\cos^2x+b^2\sin^2x)^2}=\frac{\pi(a^2+b^2)}{a^3b^3}$$  but what the integral for n ????  I hope to be there two different solution one by contour integration and the other by real analysis and thanks for all


We are given an integer which can be large as 10 to the power of 18 and we have to replace all consecutive repeating digits with zero.  I have tried by converting the integer to string but it takes a lot of time in doing type conversion from integer to string. Is there any way to do the function without converting it to string. My code by converting the integer to string -:  def replace(l):     l1 = str(l)     s = l1[0]     temp = s[0]      for i in range(1, len(l1)):         if l1[i] == temp:             s += '0'         else:             s += l1[i]             temp = l1[i]      l = int(s)     return l    Example-: Let integer be 1222433444 Expected output -: 1200430400

I've been considering fast poker hand evaluation in Python. It occurred to me that one way to speed the process up would be to represent all the card faces and suits as prime numbers and multiply them together to represent the hands. To whit:  class PokerCard:     faces = '23456789TJQKA'     suits = 'cdhs'     facePrimes = [11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 53, 59, 61]     suitPrimes = [2, 3, 5, 7]   AND      def HashVal(self):       return PokerCard.facePrimes[self.cardFace] * PokerCard.suitPrimes[self.cardSuit]   This would give each hand a numeric value that, through modulo could tell me how many kings are in the hand or how many hearts. For example, any hand with five or more clubs in it would divide evenly by 2^5; any hand with four kings would divide evenly by 59^4, etc.  The problem is that a seven-card hand like AcAdAhAsKdKhKs has a hash value of approximately 62.7 quadrillion, which would take considerably more than 32 bits to represent internally. Is there a way to store such large numbers in Python that will allow me to perform arithmetic operations on it?


I am cloning dom with jQuery append. Then I check the input value. The change and keyup functions do not work. But the input I created with jQuery append is not perceived. Can you help with this ?  Html      $(".email-address").on('change keyup', function (e) {         alert("test");         });   jQuery      $('.add-extra-email-button').click(function() {         var newDiv = $('

');          newDiv.html('
<input type="email" class="form-control email-address" name="email[]" placeholder="E-Mail">
');          $('.clone').append(newDiv);     });

I have a bit of code where I am looping through all the select boxes on a page and binding a .hover event to them to do a bit of twiddling with their width on mouse on/off.  This happens on page ready and works just fine.  The problem I have is that any select boxes I add via Ajax or DOM after the initial loop won't have the event bound.  I have found this plugin (), but before I add another 5k to my pages with a plugin, I want to see if anyone knows a way to do this, either with jQuery directly or by another option.


I have often wondered which is the better way of checking the type of an object before carrying out an operation.   I could use the 'is' operator:  if(obj is MyClass){     var tObj = obj as MyClass; }   Or I could use the 'as' operator and test for null:  var tObj = obj as MyClass;  if(tObj != null){  }   Is one preferable to the other? Is one way quicker? Does it matter?

When programming interfaces, I've found I'm doing a lot of casting or object type conversion.  Is there a difference between these two methods of conversion?  If so, is there a cost difference or how does this affect my program?  public interface IMyInterface {     void AMethod(); }  public class MyClass : IMyInterface {     public void AMethod()     {        //Do work     }      // Other helper methods.... }  public class Implementation {     IMyInterface _MyObj;     MyClass _myCls1;     MyClass _myCls2;      public Implementation()     {         _MyObj = new MyClass();          // What is the difference here:         _myCls1 = (MyClass)_MyObj;         _myCls2 = (_MyObj as MyClass);     } }   Also, what is "in general" the preferred method?


I have a fairly large figure in a LaTeX document. This figure is too large for the left and right margin of the document. This results in the figure being placed flush with the left margin, and way beyond the right margin. What I want is to do, is center the figure on the page. Can I do this, e.g. by setting a different left margin for this figure?

I have a figure that is wider than the \textwidth of my document. (I don't want to change the \textwidth.) As a result, the leftmost part of the figure is flush with the left margin, while the rightmost part spills into the right margin too much. I'd like to center the figure, so that it will exceed the \textwidth equally on both sides.


Each and every time I sign in to a Gmail account, I get a notification with "New sign-in from Firefox on Windows".  Moreover, I have another Gmail account which I sign in to on the same computer and I do not know why but I get the notification of the sign-in of the second account on the first account!  Long story short, every time I sign in to either the first account or the second one, I get a notification [a message] in the first account.  How can I disable this annoying notification?

I get at least two emails from Google every time I sign in to my account and I want it to stop.  I tried changing the notification settings in Gmail, but they're still coming and they're useless.  How can I stop this?


I have $x$ darts that I randomly throw on a dartboard with $y$ slots (the v shaped slices like you get when you cut a cake). Now I select a particular slice on the dartboard . What's the probability that no dart would have hit that slice?

You are throwing n balls into m bins randomly.   What is the probability to be empty of the first $k$ bin? Given $k$ bins are empty. What is the probability to be empty of $(k+1)th$ bin? Forget the first 2 cases, let throw balls into $m - k$ bins. What is the probability to be empty of the first bin?   Thank you


My mom was in the USA twice for 5.5 months, she had 1 year visa. She had been assisting me with my child, so l could work. I believe that she was refused by mistake due to a communications misunderstanding. The visa officer accused her of working as a barber during her stay in the USA, actually I’m working as a barber, she didn’t work anywhere here except to take care of my infant child. She had B1/B2 visa.  Can I apply for any of the waiver? Ds160 form was correct.

My father had a valid 10 year visit visa and he visited the US a couple of times. His visa expired recently, so he applied  for renewal. In the course of applying, he made a mistake on his application DS160 form: in the City of Birth space, he wrote the name of the city where he lives, instead of the city where where he was born as shown in his passport.   His visa was refused, citing Section 212(a)(6)(C)(i) Misrepresentation. He was sent a refusal letter, with 'Classes of Applicants Eligible to Apply for Waiver under INA 212(i)' ticked/checked.   What is our next step in order for him to get a visa?  Edit: I would like to add that my father's provided sponsorship from an American citizen and no other documents from him. They never asked to see his documents. How/where do we apply for the waiver?


Imagine, there are two files   test.php index.php   In test.php there are only a html button with id click.  In index.php there are also only a html button with id send.  If I send an ajax request to test.php file from index.php then the button with id click from test.php should be inserted within a div in index.php. Now I want this button to hide p element when it is clicked within index.php.  Note: onclick attribute should not come with #click button.  How to do that? I am currently using android phone to ask this question. So I am not able to write the question with examples.


I tried to find bounds for the sum using regular techniques, but couldn't get any result nor contradiction.

Question is to check if : $\sum_{n=1}^{\infty}\frac{(\log\log2)^n}{n!}>\frac{3}{5}$   the problem is that i am sure that this series$\sum_{n=1}^{\infty}\frac{(\log\log2)^n}{n!}$ is convergent (if it is not then i would be very happy as i will then be done.)  I would be thankful if someone can help me out with solving this.


We are working on a news website, we have a country category as a parent and then a city child sub category.  Which method would be best for SEO?   view/uk, view/uk/london view/country/uk, view/city/london view/uk, view/london   Most of the team went with option 3 since it's easier, but wanted to hear your feedback.

Please explain which is the best URL structure and why:  website.com/apartments-to-let/manhattan   or  website.com/apartments-to-let-manhattan   This is a property site. Is it best for the bots to break the properties/URL's down in categories?


In Infinity War, Doctor Strange, Tony Stark, and Spider-Man find themselves on a spaceship, having just ejected The Maw into Space. Strange asks Tony if he (Tony) can get them home by using the ship.   Why doesn't Strange just open a portal and jump through as he demonstrated he could do on earth earlier in the film, and again later when they are on Titan? Previously there were no hints that distance is a factor - in Dr Strange he is able to open one to an alternate universe so surely opening one to somewhere in his own galaxy or universe should be no problem.

After       the attack on Earth where Doctor Strange is abducted and Iron Man and Spider-man rescue him, Doctor Strange starts asking how they plan to get back to Earth.   Why couldn't he just use his sling-ring teleportation to return? There is later confirmation that he can still do it (locally, at least). I understand they later decided against returning in general, but in the moment they seemed to preclude that option.


look at symbol in the first line  as you seen that symbol I think it's mu symbol how I can't show this symbol using latex

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


Is there a way to grep for a regular expression on an Ubuntu server and then find and replace it with another string? I am using the following command right now, but it doesn't account for actually changing the grepped string:   grep --recursive --ignore-case “string”   If I use awk or sed how would I write it to replace for instance "wavbyte" with "gitship" for all instances where "wavbyte" occurs for my entire server?

Replacing strings in files based on certain search criteria is a very common task. How can I    replace string foo with bar in all files in the current directory? do the same recursively for sub directories? replace only if the file name matches another string? replace only if the string is found in a certain context? replace if the string is on a certain line number? replace multiple strings with the same replacement replace multiple strings with different replacements


I have
 tag and in menu
日本刀日本刀日本刀日本刀
   but I want wrap text when text over 16 byte

I have a long string (a DNA sequence). It does not contain any whitespace character.  For example:  ACTGATCGAGCTGAAGCGCAGTGCGATGCTTCGATGATGCTGACGATGCTACGATGCGAGCATCTACGATCAGTCGATGTAGCTAGTAGCATGTAGTGA   What would be the CSS selector to force this text to be wrapped in a html:textarea or in a xul:textbox?


I have a AJAX call that looks like this and I have included the  tag as well:  <script>         $.post("../processor/get_notifications.php",             {                 id: <?php echo $_SESSION["id"]; ?>             },             function(data, status){                console.log("Data: " + data + "\nStatus: " + status);             }); </script>   And the .php file looks like this:      <?php if(isset($_POST["id"])){     require '../includes/backbone.php'; //It contains the server information     $connection = mysqli_connect($server_name, $database_username, $database_password, $database_name);     $sql = "SELECT user_json FROM users WHERE id = " . $_POST["id"] . "";     $result = mysqli_query($connection, $sql);     echo $result; }   So, I am trying to pass the user_json stored in the database to the page from where the AJAX call is done. But, It shows an internal server error. I guessed that the error was caused as the variable $result may be an object. And when I tried to check if the type of the variable was object using echo gettype($result);, it showed object in the console. So, I tried to change the object to string using three methods out of which none worked:   $result = "'" . $result . "'"; //which I was sure wouldn't work $result = (string)$result; $result =json_decode($result); //which didn't make sense. So, How am I supposed to get the object in the page to do something like:  document.write(object["about"]); or so on?

How do I use the json_encode() function with MySQL query results? Do I need to iterate through the rows or can I just apply it to the entire results object?


I've done some small laptop stuff without the wrist strap, but I might replace a logic board of a  and will be working on it for a long time. I have wrist straps and might as well use one. I'm real dumb when it comes to grounding stuff, sorry. Will plugging the extension cord into the wall outlet and then clipping to the cord pin ground me? I read that clipping it to the USB metal in the laptop is not smart, so I'm not clipping it to the inside of my laptop.

I have gone through  on Superuser, while it provides good information, I still have a specific question from electrical/electronics engineering point of view.  Is it wrong and unsafe to connect the other end of the ESD wrist strap to the ground point on the wall socket?  What harm can it do and if it’s wrong, why?  I was watching a Youtube video about assembling computers by a user who seems to be a professional and he says he has been in the business for over 2 decades.   The video discourages connecting ESD strap to wall socket ground, it also says that when you connect ESD strap to metallic part of cabinet, remove the power plug from the PSU. However except a reasoning that you could get electrocuted with such a setup, no further technical explanation is given.  I have worked in an IT company that was TL9000 quality certified. This standard demands ESD protection deployment wherever necessary. All relevant test benches there had ESD mats connected to common ground. All terminals had a point to plug the ESD strap’s other end and all those were connected to ground and eventually going to the earth pit. So discouraging  ESD strap connection to wall socket ground (that ultimately goes into the Earth pit) is a totally new concept to me.


I'm flying in economy plus with United airlines. What's the best possible seat to get with the most room? For legs, body, etc

Are there online resources for researching seat sizes and leg room of various planes of various airlines?  I'd like to know whether JAL international flight economy class seats are  (compared to a Virgin Australia domestic economy class seat), or whether I'm just imagining it.


In my salesforce org, I have a list of Accounts which was loaded externally using CSV file using Data loader tool. The problem is that 3 team member of my team uploaded same data thrice and thats why duplicates Account data coming. I need to remove all those multi-duplicate account.  How can I remove that? What is the correct way of doing this rectification? I assume my org might have 1000 unique Accounts, so due to developers error, count has become 3000. This is terrible.

How can I remove duplicate records for accounts and contacts at once from talent rover?I tried to use the dupe eliminator but I would have to search the accounts and contacts one by one and merge.Is there any other way?


I'm logged in yet when I post a comment, it always comes up with an artificial userisxxxxx. how to get my user name to display instead of an artificial userxxxxxx?

How can I change (or remove / reset ) my name on a site in Stack Exchange network?


] Am trying to render this glass in blender, it wont show what,s behind it. its not a background, it is a colored mesh

When using Eevee, an object with a glass material (in this case: Principled BSDF, trasmission set to 1.0) doesn't seem like it can be looked through: it's completely opaque.  See for instance the material for the blue cube in this scene:    How can I get my glass material to be transparent?


I download the deb package from the official cisco's page, before run sudo dpkg -i PacketTracer_730_amd64.deb I get this error:  Selecting previously unselected package packettracer. (Reading database ... 500916 files and directories currently installed.) Preparing to unpack PacketTracer_730_amd64.deb ... Unpacking packettracer (7.3.0) ... dpkg: dependency problems prevent configuration of packettracer:  packettracer depends on libdouble-conversion1; however:   Package libdouble-conversion1 is not installed.  packettracer depends on qt-at-spi; however:   Package qt-at-spi is not installed.  dpkg: error processing package packettracer (--install):  dependency problems - leaving unconfigured Processing triggers for bamfdaemon (0.5.3+18.04.20180207.2-0ubuntu2) ... Rebuilding /usr/share/applications/bamf-2.index... Processing triggers for gnome-menus (3.36.0-1ubuntu1) ... Processing triggers for desktop-file-utils (0.24-1ubuntu2) ... Processing triggers for mime-support (3.64ubuntu1) ... Processing triggers for gnome-icon-theme (3.12.0-3) ... Processing triggers for shared-mime-info (1.15-1) ... Errors were encountered while processing:  packettracer   when I search for those package libdouble-conversion1 and qt-at-spi seems like they aren't compatible with Ubuntu 20.04 and aren't in the default ubuntu repositories.  How can I install this dependencies?

I am trying to install Packet Tracer 7.3 (latest version) on Ubuntu 20.04 but do not succeed to so so because of two dependencies which are not installable ("libdouble-conversion1" and "qt-at-spi").  However I successfully installed the previous version (7.2.2) which was available in an Ubuntu installer format (.run file) but I nothing happens when I run it from my gnome desktop.  I am quite a newbie in Linux so I appologies if answers are obvious...  Thanks in advance ;-)  Denis


When I shut down my Pop OS, for a fraction of a second the screen turns into a console and prints some statements before shutting down. This happens very fast, and it's impossible to read or capture and I can't find anything referring to this. All I'm able to notice is the word "Failed". This kind of worries me. Any one knows what this is about? I'm not dual booting and I only have one drive, entirely dedicated to the OS. Is there a way to read this message properly? Like, is there a log file somewhere?

I'm using Lubuntu 11.10. Every time I shut down I can read FAIL in red letters, but I can not read more.   So, how to read the log messages and try to solve the  problem?


I automatically get a question if I want to upgrade to 16.04 from 14.04. I answer "yes" and short after the process has start I get:  W:Failed to fetch http://ubuntu.mirror.neology.co.za/ubuntu/dists/xenial-updates/universe/binary-amd64/Packages  Hash Sum mismatch E:Some index files failed to download. They have been ignored, or old ones used instead.   When I close the display the system reverses what has been done to that point and later asks if I want to upgrade again.  Every time I get the same results. Is there some I should be doing to get the process to successfully upgrade ?

When I check for updates, I get a "Failed To Download Repository Information" error.   This is what comes up under details:   W: Failed to fetch gzip:/var/lib/apt/lists/partial/us.archive.ubuntu.com_ubuntu_dists_natty_main_source_Sources  Hash Sum mismatch,  E: Some index files failed to download. They have been ignored, or old ones used instead.


We say "I will contact you by letter", but we say "He was knocked down by a bus". Why is "letter" not preceded by an article?

What article should be used in the following sentence?     He was English by [a/the/] blood.   I feel there should be a zero article here, but I was taught that the zero article is impossible in English.


We want to solve this without using power series.    I know I should use Cauchy's estimates formula, but I can't seem to get a correct proof.  We want to show that $f'(z)$ is constant and the result will then follow from Liouville's theorem.    Choose $R>0$ and consider $\overline{B_R(0)}$. Then for $z \in \partial \overline{B_R(0)}$, we have $|f(z)|\le A|z|+B \le AR+B$.  So, $$|f'(0)| \le \frac{1}{R}(AR+B) = A+\frac{B}{R}.$$  As $R \to \infty$, then $|f'(0)| \le A$.  However, I need to show that $|f'(z)|$ is bounded and thus constant.  How can I continue?

Suppose that an entire function $f(z)$ satisfies $\left|f(z)\right|\leq k\left|z\right|^n$ for sufficiently large $\left|z\right|$, where $n\in\mathbb{Z^+}$ and $k>0$ is constant. Show that $f$ is a polynomial of degree at most $n$.


I have declared the enum as follows in python.I don't know how to use them.When I create an instance of this class it gives error as two arguments are required one given.  class CBarReference(Enum):     ThisBar = 0, NextBar = 1, Undefined=2 a=CBarReference()   I know what error is but I don't know what to give as the second argument other than self.

I'm mainly a C# developer, but I'm currently working on a project in Python.  How can I represent the equivalent of an Enum in Python?


Find the minimal polynomial of the $n$-dimensional matrix $(a_{ij})$ when the matrix elements $a_{ij}$ have the form $a_{ij} = u_i v_j.$    Let $A=uv^T$ where $u,v$ are column vectors.  Then rank$(A)\leq$rank$(u)\leq1.$ So kernal$(A)\geq n-1.$ That is, the geometric multiplicity $\geq n-1.$ According to Jordan decomposition theorem, the number of Jordan blocks w.r.t. $0\ \geq n-1.$ Therefore, the algebraic multiplicity of $0$  $\geq n-1.$  Suppose rank$(A)=1,$ how do I find the other eigenvalue?

I have come across a question about determining possible minimal polynomials for a rank one linear operator and I am wondering if I am using the correct proof method.  I think that the facts needed to solve this problem come from the section on Nilpotent operators from Hoffman and Kunze's "Linear Algebra".     Question: Let $V$ be a vector space of dimension $n$ over the field $F$ and consider a linear operator $T$ on $V$ such that $\mathrm{rank}(T) = 1$.  List all possible minimal polynomials for $T$.   Sketch of Proof:   If $T$ is nilpotent then the minimal polynomial of $T$ is $x^k$ for some $k\leq n$.  So suppose $T$ is not nilpotent, then we can argue that $T$ is diagonalizable based on the fact that $T$ must have one nonzero eigenvalue otherwise it would be nilpotent (I am leaving details of the proof of diagonalization but it is the observation that the characteristic space of the nonzero eigenvalue is the range of T and has dimension $1$).  Thus the minimal polynomial of $T$ is just a linear term $x-c$.    Did I make a mistake assuming that $T$ can have only one nonzero eigenvalue?  Thanks for your help


Proper answer friendly greeting, "How are you?" I am "well" or I am "good"  "I am well" sounds like I'm saying I'm not sick. "I'm good," or "good" accompanied by a friendly nod sounds much better.

The greeting How are you? is asking How are you doing in general?  —     How are you?   I'm well. [Misunderstood the question.]   because well as an adjective which means:     in good health especially after having suffered illness or injury   This would be an answer to How are you doing physically, how is your health?  —     How are you?   I'm good.  [Misunderstood the question.]   because good as an adjective means:     having moral excellence or admirableness   This would be an answer to      How would you describe your character, superman?    I'm good.   —     How are you?   I'm doing good. [Grammatically incorrect.]   because good is an adjective, not an adverb.  —     How are you?   I'm doing well. [Correct.]   because well is an adverb describing how you are doing.     How are you?   I'm doing fine. [Correct.]   because fine is an adjective which means:     being satisfactory or in satisfactory condition     Why do so many people say one of the first three responses?


We have like 20 Office 2010 Product Key Boxes but we have no clue which one are used and which one are free.  Is there any way to check which one are free?

Without a product key being labelled, is there is any way to identify what Microsoft software product a given product key is meant to activate?   Let's say for example I had the product key ABCDE-FGHIJ-KLMNO-PQRST-UVWXY, but I had no clue if was meant for Windows 7 Ultimate, Windows 7 Home Premium, Vista Ultimate, or even Office 2010. Is there a way I could identify the software product the key is meant for (or at least get a good estimate)?     Note: I have searched and searched many times on the Internet, but the only results I ever find are how to recover a lost product key by using something like . This is not what I am looking for.


It is written on Wikipedia:  In mathematics, the continuum hypothesis (abbreviated CH) is a hypothesis about the possible sizes of infinite sets. It states: There is no set whose cardinality is strictly between that of the integers and the real numbers.  Suppose that CH is not true, that is that there is such a set, call it $C_1$, so, $|\mathbb Z|<|C_1|<|\mathbb R|$ But, does some principle "forbids" us to suppose that there are also sets $C_2$ and $C_3$ so that we have $|\mathbb Z|<|C_2|<|C_1|<|C_3|<|\mathbb R|$, and $4$ more sets with cardinalities between those $5$, and so on and so on...  That is, if CH is not true, can there be an infinitely countable number of sets $S_i$ between $\mathbb Z$ and $\mathbb R$ so that we have $|\mathbb Z|<| S_1|<...<|S_{\infty}|<|\mathbb R|$. And, if there cannot be an infinitely countable number of sets between $\mathbb Z$ and $\mathbb R$, all with different cardinalities, can there be a finite number of them (a finite number greater than $1$)?

Assume the continuum hypothesis is false, and add that as an axiom to ZF set theory. How many cardinalities are between the rationals and the reals in this case? Only one? Infinitely many? Countably many? Uncountably many? What are the possibilities to the quantity of counterexamples?


I am very new to QGIS and I simply have two tif images which I need to do pixel analysis on so I can compare the change in vegetation over time. I have no idea how to go about this and if anyone has some advice for me I would be very grateful

From  page:  Change detection for GIS (geographical information systems) is a process that measures how the attributes of a particular area have changed between two or more time periods. Change detection often involves comparing aerial photographs or satellite imagery of the area taken at different times. The process is most frequently associated with environmental monitoring, natural resource management, or measuring urban development  How is the comparison done? With what tools? I feel that the description is not complete. Or something is missing. Where or in which books can I find more information about Change Detection? What tools should I use to perform such an analysis using the data in a shapefile? (only open-source please)  Some papers on change detection (theory and techniques)  Trend change detection in NDVI time series: Effects of inter-annual variability and methodology Forkel, M. , Carvalhais, N. , Verbesselt, J. , Mahecha, M.D. , Neigh, C. , Reichstein, M. (2013) Remote Sensing 5 (2013)5. - ISSN 2072-4292 - p. 2113 - 2144. Shifts in global vegetation activity trends Jong, R. de , Verbesselt, J. , Zeileis, A. , Schaepman, M.E. (2013) Remote Sensing 5 (2013)3. - ISSN 2072-4292 - p. 1117 - 1133. Relationships between declining summer sea ice, increasing temperatures and changing vegetation in the Siberian Arctic tundra from MODIS time series (2000–11) Dutrieux, L.P. , Bartholomeus, H.M. , Herold, M. , Verbesselt, J. (2012) Environmental Research Letters 7 (2012)4. - ISSN 1748-9326 - p. 12. Near real-time disturbance detection using satellite image time series Verbesselt, J.P. , Zeileis, A. , Herold, M. (2012) Remote Sensing of Environment 123 (2012). - ISSN 0034-4257 - p. 98 - 108. Trend changes in global greening and browning: Contribution of short-term trends to longer-term change Jong, R. de , Verbesselt, J. , Schaepman, M.E. , Bruin, S. de (2012) Global Change Biology 18 (2012)2. - ISSN 1354-1013 - p. 642 - 655. Phenological change detection while accounting for abrupt and gradual trends in satellite image time series Verbesselt, J. , Hyndman, R. , Zeileis, A. , Culvenor, D. (2010) Remote Sensing of Environment 114 (2010)12. - ISSN 0034-4257 - p. 2970 - 2980. Detecting trend and seasonal changes in satellite image time series Verbesselt, J. , Hyndman, R. , Newnham, G. , Culvenor, D. (2010) Remote Sensing of Environment 114 (2010)1. - ISSN 0034-4257 - p. 106 - 115. (I'll add more in the future as If I discover more notable  papers)


Now I'm interesting in the question as follow,  Let $f\in C^1(\mathbb{R})$ and $f$ is bounded, $\lim_{x\rightarrow+\infty}f'(x)=0$, then $\lim_{x\rightarrow+\infty}f(x)$ exists.  Is this statement true? If not, please give a counterexample!  My try: if we remove the boundness condition of the function $f$, I can give a counterexample on the half line, namely, $f(x):=\ln x$.  Any answer will be appreciated!

I have come across the following question:  Say $f(x): [0,\infty) \rightarrow \mathbb{R}$ differentiable. Given $\lim_{x\rightarrow\infty}f'(x) = 0$, does this imply an existence of a limit (finite or not) of $f$ at infinity?  From what I tried to do, looking at the definition of the derivative: $\lim_{\substack{h\rightarrow0 \\ x\rightarrow\infty}}\frac{f(x+h)-f(x)}{h} = 0$ you could say that $\lim_{\substack{h\rightarrow0 \\ x\rightarrow\infty}} f(x+h) = \lim_{x\rightarrow\infty} f(x)$. Is it enough to prove the existence of a limit? if not, is there another way to prove or disprove that?


Does a real $3\times 3$ matrix $A$ that satisfies conditions $\operatorname{tr}(A)=0$ and $A^2+A^T=I$ ($I$ is an identity matrix) exist?  Thank you for your help.

Is there square matrix $A$ of size $3$ with real entries such that  $$ \operatorname{tr}(A)=0\text{ and }A^2+A^T=I. $$  I have proved that there is not with size $2$ using definition of  "trace", but for size $3$ it becomes complicated.  Here is the sketch of the proof for $2$. $$ a_{11}+a_{22}=0,\\ a_{11}^2+a_{12}a_{21}+a_{11}=1,\\ a_{11}a_{12}+a_{12}a_{22}+a_{21}=0,\\ a_{21}a_{11}+a_{21}a_{22}+a_{12}=0,\\ a_{12}a_{21}+a_{22}^2+a_{22}=1. $$ Putting $a_{11}=-a_{22}$ it is easy to see that above inequalities can't be true together.   Thanks!


Evaluate $$\sum_{r=1}^{20}\frac{1}{r(r+1)}$$  It splits into $$\sum_{r=1}^{20}\frac{1}{r}-\sum_{r=1}^{20}\frac{1}{r+1}$$  I'm stuck on how to apply the standard result $\sum_{r=1}^{n}\frac12n(n+1)$ to it. It may be simpler to use the method of differences but is that the only straightforward way?

This is a 2 part problem.  Part I  I need help finding a formula for this sequence of numbers:  $$\frac{1} {1\times 2} + \frac {1} {2\times3} + \cdots + \frac {1} {n(n+1)}$$  Part II  I need to prove the formula conjectured in Part I.


Let $\omega^{1}$ a 1-form defined in an open set $U\subset\mathbb{R}^{n}$. Assume that for each closed differentiable curve $c$ in $U$, $\int_{c}{\omega^{1}}$ is a rational number. Prove that $\omega^{1}$ is closed.   My approach: Let $c_{0},c_{1}:[0,1]\to U$, two curves homotopics. If $\omega^{1}$ is a 1-form closed on $U$, then the line integral along to $c_{0}$ and $c_{1}$ coincide $$\int_{c_{0}}{\omega^{1}}=\int_{c_{1}}{\omega^{1}}$$ So my idea is fixed two rational number, then for the homotopy of $c_{0}$ and $c_{1}$, I'm "obliged" to go through a irrational number.  Edit: I know that question was asked here : , but anyway I cannot finish the problem

The following problem comes from do Carmo's book Differential Forms and Applications, Chapter 2, Exercise 4:  Let $\omega$ be a differentiable 1-from defined on an open subset $U\subset \mathbb{R}^n$. Assume that for each closed differential curve $C$ in $C$, $\int_C \omega$ is a rational number. Prove that $\omega$ is closed.   Can anyone give some hints? My idea was that we could try to show the integral vanishes if the curve lies in $N_\epsilon (p)$ (i.e. a small neighborhood around $p$) for any $p$ in $U$ and use the Poincare Lemma, but failed.


I am trying to show the edges in my render but it is not working.  To see what I mean, I am trying to create the same result as the image below in Blender render.  Of course I did some research. I came across  question but when I follow the instructions of the answers, my objects just disappear if I render.  So, is there somebody who can help me out with rendering the edges?

How can an object be to rendered using the cycles render engine so that it renders with normal maps, specular maps, etc, and shows wireframes of the mesh and the subdivision surface modifier? For example, -   This is done with a texture, but is there another way?


I am a self-employed I.T. I was wondering if there was a way to download Spotify to Ubuntu Linux. I have the newest update.  Thanks, Hunter

A while ago Spotify (the streaming music service) came out with a preview for Linux of their client.  So what should I do?


I'm very new to road biking and struggling to set up my cycle computer on my Triban 500 SE.. Manufacturing Info about bike here :    To confirm they are 650 tyres which are 23mm wide.  My question is about wheel circumference which I need to be converted into mm. Does anybody know or understand how to work this out?...  Note : I am almost positive this is a very noob question.. However, saying that there is little information about this on the web so an answer that explains how they got to it would be appreciated and would definitely help future newbies!

I have bought the Campangolo Khamsin wheelset, and now I would like to set the right wheel size in my Trek Incist 8i cycle computer. Before I do the custom wheel setting, I would like to know what would be the best choice?    The wheel has ETRTO 622x15c printed on it.   The computer comes with the following wheel sizes defined:  700x20, 700x23, 700x25, 700x28, 700x32, 700x35, 700x38, 26x1.5, 26x1.5, 26x1.90, 26x1.95, 26x2.0, 26x2.1, 26x2.2.  So, if anyone here knows what would be the closest match I would be happy to know.


For security reason i would like to enforce users to set 10 character password length .  How can i modify this policy ?

Is there any way to set up minimum passcode requirements, such as a minimum length, requirement of mixed case alphanumerics and at least 1 symbol in the passcode, and enforce that at passcode changes?


I want the general meaning of the bold phrase in this text: If so, does the israeli public think israel should do something about USA? As you can see in the diagram, it certainly does. Look at the reds. Many would support a military initiative in response to this threat: military action against USA, preferably in coordination with Israel. We see military activism, sometimes even at the risk of an escalation leading of war. By the way, it comes up in other questions too, about USA arming ISIS with advanced weapons. Interestingly, in the past, the more an israeli attack against American nuclear facilities become realistic, the less support it received.


I want to compare two list with objects of two different classes. These are the classes:  namespace AngularWebApplication.Models {     public class AggregationLevelConfigurationPresentation     {         public byte AggregationLevelConfigurationId { get; set; }         public int ProductionOrderId { get; set; }         public string Name { get; set; }         [ ... ]     } }  public class AggregationLevelConfiguration : IEquatable<AggregationLevelConfiguration> {     public byte AggregationLevelConfigurationId { get; set; }     public int ProductionOrderId { get; set; }     public string Name { get; set; }     [ ... ] }   I want to get the elements in presentations list that are not in currentLevels:  List presentations; List currentLevels;  List<Models.AggregationLevelConfigurationPresentation> newLevels =     presentations         .Select(l => new { l.AggregationLevelConfigurationId, l.ProductionOrderId })         .Except(currentLevels.Select(l => new { l.AggregationLevelConfigurationId, l.ProductionOrderId }))         .ToList();   But I get the following error when I do the Except:  Error   CS0029  Cannot implicitly convert type  'System.Collections.Generic.List<<anonymous type: byte AggregationLevelConfigurationId, int ProductionOrderId>>' to  'System.Collections.Generic.List<AngularWebApplication.Models.AggregationLevelConfigurationPresentation>'   I think the problem is in the new { l.AggregationLevelConfigurationId, l.ProductionOrderId } but I don't know how to do the Except with list of objects from different classes.  I need the objects in presentations list that they aren't in currentLevels using AggregationLevelConfigurationId and ProductionOrderId as primary key.

I got an anonymous type inside a List anBook:  var anBook=new []{  new {Code=10, Book ="Harry Potter"}, new {Code=11, Book="James Bond"} };   Is to possible to convert it to a List with the following definition of clearBook:  public class ClearBook {   int Code;   string Book;  }   by using direct conversion, i.e., without looping through anBook?


I was looking through my bathroom window this night and I was wondering if any of the photons my retina is hit with are from 13 (40) billion light years away ?!  I was looking through it a few seconds, was that too less of a time?  Do I need a Hubble for this?

How can astronomers see light from shortly after the big bang? How did we get "here" before the light that emanated from our "creation"?


I have a deploy user that has sudo privledges.  I can't sudo cd into the directory, but I can list it like:  sudo ls /root   How can I cd into the folder, or is that not possible?

I tried to use sudo cd name_of_dir but am getting the error message:   sudo: cd: command not found   Is there any other way to enter a directory owned by another user which has 700 permission?


Sometimes I visit my wordpress website on godaddy, and looks like the site is slow. But when I refresh it goes fast.  I wonder how often this occur to my visitors on the month. Is there a way to know?

The connection speed our webapp is showing (from my office) is much slower than my connection speed to a SpeedTest.net site in the same city.  I can test my internet using SpeedTest.net to Houston (where our server is): 37 Mb/s And we have a built in test in our app which shows 3.5 Mb/s  I'd like to test both "houston" and $ourDomain with the SAME service. But all I can find are sites that test the actual page, which I assume introduces a lot of extra variables.


I'm running 12.04 x64 with a GeForce GTX650. When I play games, I turn v-sync on to prevent screen tearing, and it works fine.  But desktop is another problem: I can't get desktop (most notably, the web browser) to stop tearing the image. I turned "Sync to VBlank" on, but it didn't help.    Thanks in advance!

I have that problem which seemingly afflicts many using the proprietary Nvidia driver:     Video tearing: fine horizontal lines (usually near the top of my display) when there is a lot of panning or action in the video.   (Note: switching back to the default nouveau driver is not an option, as its seemingly nonexistent power-management drains my battery several times faster)  I've tried Totem, Parole, and VLC, and tearing occurs with all of them.  The best result has been to use X11 output in VLC, but there is still tearing with relatively moderate action.  Hardware:  MacBook Air 3,2 -- which has an Nvidia GeForce 320M.    There are two common fixes for tearing with Nvidia prop drivers:   Turn off compositing, since Nvidia proprietary drivers don't usually play nice with compositing window managers on Linux (Compiz is an exception I'm aware of).  But I use an extremely lightweight window manager (Awesome window manager) which is not even capable of compositing (or any cool effects).  I also have this problem in Xfce, where I have compositing disabled. Enabling sync to VBlank.  To enable this, I set the option in nvidia-settings and then autostart it as nvidia-settings -l with my other autostart programs.  This seems to work, because when I run glxgears, I get:  $ glxgears  Running synchronized to the vertical refresh.  The framerate should be approximately the same as the monitor refresh rate. 303 frames in 5.0 seconds = 60.500 FPS 300 frames in 5.0 seconds = 59.992 FPS   And when I check the refresh rate using nvidia-settings:  $ nvidia-settings -q RefreshRate Attribute 'RefreshRate' (wampum:0.0; display device: DFP-2): 60.00 Hz.   All this suggests sync to VBlank is enabled.  As I understand it, this is precisely designed to stop tearing, and a lot of people's problem is even getting something like glxgears to output the correct info.   I don't understand why it's not working for me.   xorg.conf:   Example of observed tearing::


Let $A = \begin{pmatrix} 1 &  1& 1\\  1 & 2 &3 \\  1 &4  & 5 \end{pmatrix}$ and  $D = \begin{pmatrix} 2 &  0& 0\\  0 & 3 &0 \\  0 &0  & 5 \end{pmatrix}$.  It is found that right-multiplication by D multiplies each column of A by the corresponding diagonal entry of D, whereas left-multiplication by D multiplies each row of A by the corresponding diagonal entry of D.  Construct a 3 x 3 matrix B, not the identity matrix or zero matrix, such that $AB=BA$.

Given a matrix $A$ over a field $F$, does there always exist a matrix $B$ such that $AB = BA$? (except the trivial case and the polynomial ring?)


What is the etymology of the 'here' in the expression 'these here'?  I am unable to find a dictionary definition, although I believe the expression could also be simply these, or even those.  So why did the 'these here' construct come about? It sounds like dialect, which isn't always explainable, but I'd appreciate any actual references to why and where it came about. An example is:     Probably she was one of these here New Women. (The Wheels of Chance, H.G. Wells)     It also can be formed with other demonstrative determiners, while using either adverb 'here' or 'there', for example:        This here   Those here   That there

I have already seen these here questions:   but they don't appear to me to answer the question I am about to ask.    If I say:      This lovely lady is my daughter. So, be nice, will you?   'lovely' is obviously an adjective pre-modifying the subject noun.   But if say:       This here lady is my wife. So, keep your paws off, will yah?   1- Is 'here' an adjective here?      2- Which parts of the world (of the USA?) and/or what kind of people use the construction: "This here + noun..."?    I never use this kind of construction, but I sometimes here it in movies...     E.g. in "Night at the Museum" (2006):     Octavius, hold on. This ain't your fight.    This here giant's on our  land.   ...   Now, this here's King Ahkmenrah.   His tablet is what brings  you to life every night.