def x(lst):    z = 0    for a in range(len(lst)):        for b in range(len(lst)):            mx = lst[0][0]            if mx &gt; z:                z = mx               return z.   I'm trying to find the complexity Big O of the function. So with the nested list, it would be O(n^2), but it also had a condition statement that would go through all the elements in the list, so would it it be O(n^3) ?
Most people with a degree in CS will certainly know what . It helps us to measure how well an algorithm scales.   But I'm curious, how do you calculate or approximate the complexity of your algorithms?
Riemann integrabilty of an indicator function Consider the following function on $[0,1]$:   $$f(x)=\begin{cases}1&amp;x\in\{a_1,a_2,\dots,a_n\}\\0 &amp;\text{otherwise}\end{cases}$$   The $a_i$ are fixed and all in $[0,1]$. Determine whether $f$ is Riemintegrable or not.   By the Riemann&ndash;Lebesgue criterion $f$ is Riemann integrable. How to prove directly? Clearing NSUserDefaults I'm using +[NSUserDefaults standardUserDefaults] to store application settings. This consists of roughly a dozen string values. Is it possible to delete these values permanently instead of just setting them to a default value? Do I need to use a comma between two adjectives? You can also contact me to customize your template, or create a new unique one.   Do I need to put a comma between the new and unique adjectives in this sentence?  In my native language (if I am not mistaken) we don't put a comma if the adjectives are of a different type. Not sure about English though, and if it's the case here anyway. Any help would be appreciated! One of my favorite quotes is by Alvin Toffler which says:     The illiterate of the 21st century will not be those who cannot read   and write, but those who cannot learn, unlearn, and relearn.   The way I understand "relearn" in the quote is to learn something new that is different from what was originally learned.  I'm wondering in general if "relearn" convey learning the same thing again, or a different thing, or it depends on the context of the sentence. Is the same thing true for "learn again"? What is the fundamental group of $(\mathbb{C} \setminus {\{0\}})~/~\{e,a\}$, where $e$ is the identity homeomorphism and $az = -\bar{z}$?  Clearly this is homeomorphic to the half cylinder , which is homotopy equivalent to the half circle.  But what is the fundamental group of the half circle? How are Pokestops chosen? After playing the game for a little while, I've noticed that Pokestops are chosen seemingly at random locations on the map. A few of them are even in inaccessible places; an abandoned church building, inside of an airforce base, etc. How are these locations chosen as Pokestops? I use a brick and mortar bank for some of my savings. I’d love to get a CD interest rate closer to what Ally or other online banks offer.   Are brick and mortar banks will to negotiate with customers on interest rates? For instance, if I went into a branch and said I’m moving my money to Ally unless the bank matches Ally’s rates, do I have any chance of getting them to? How are java.lang.Object's protected methods protected from subclasses? The keyword protected grants access to classes in the same package and subclasses ().  Now, every class has java.lang.Object as superclass ().  Hence I conclude that every class may access java.lang.Object's methods even if they are protected.  Take a look at the following example:   public class Testclass {   public Object getOne() throws CloneNotSupportedException {     return this.clone();   }   public Object getTwo() throws CloneNotSupportedException {     return ((Object) this).clone();   } }   While getOne() compiles fine, getTwo() gives   Testclass.java:6: clone() has protected access in java.lang.Object         return ((Object) this).clone();   I neither understand why getTwo() doesn't compile nor what's the difference (regarding the access of java.lang.Objects members) with getOne(). How to address a professor in letter? Why does this code:  class A {     public:          explicit A(int x) {} };  class B: public A { };  int main(void) {     B *b = new B(5);     delete b; }   Result in these errors:   main.cpp: In function ‘int main()’: main.cpp:13: error: no matching function for call to ‘B::B(int)’ main.cpp:8: note: candidates are: B::B() main.cpp:8: note:                 B::B(const B&)   Shouldn't B inherit A's constructor?  (this is using gcc) My question isn't how they receive the energy to jump, but why.  When someone views an element's emission spectrum, we see a line spectrum which proves that they don't exist outside of their orbitals (else we would see a continuous spectrum).  Electrons can be released in the form of beta decay, thus proving that they are capable of traveling outside of orbitals contrary to the statement my teacher said that they stay within orbitals. Then, to add to the confusion, the older model of rings floating around a nucleus has, from what I can tell, been outdated, which would support this model. My teacher's explanation was that the electrons made a quantum jump of some kind. How do electrons move between orbitals or do we know how they jump, excluding the reason that energy causes them to jump, and why are positrons formed sometimes instead of electrons in Beta decay?  When I'm asking "how do electrons jump" I would like to know how an electron can jump between each orbital such as how it moves and how it knows where to jump since it appears to be a jump where the electron doesn't slow into a orbital position. Specifically how they jump what is this Atomic electron transition, I understand that they jump and that they do this through absorbing and releasing energy but what is this Atomic electron transition other than what is already on the wikipedia article . Question regarding the Fibonacci sequence Given the Fibonacci sequence $(F_1, F_2,F_3, ...)$ how do I prove that if $m|n$ then $F_m|F_n$? Can this be proven with mathematical induction? As of now, my desktop has begun showing the contents of my home folder (~) instead of the contents of ~/desktop. I must have changed something, but I have no idea what, or what I was doing exactly when it happened.  How do I re-point gnome to the right folder?  I'm running Ubuntu 11.04. How can a particle's position be random and uncertain in quantum mechanics if it is already pre-determined in relativity? I use a 7805 for a project where the circuit needs a higher current (~2.8&nbsp;A) at 5&nbsp;V. So I assume that if I use both ICs in parallel I can increase the maximum current capacity. Would it work? Show that $\ker \hat{T} = \text{ann}(\text{range } T)$ This is an old exam problem: Let $V$ and $W$ be finite dimensional vector spaces over a field $F$ and let $T: V \to W$ be a linear transformation. Define $\hat{T}: W^* \to V^*$ by $(\hat{T}(f))(v)=f(T(v))$. Here, $U^*$ denotes the dual vector space $U$. Since $\hat{T}$ is a linear transformation prove $\ker \hat{T} = \text{ann}(\text{range } T)$ where $\text{ann}(Y) = \{g \in U^* : g(y)=0 \text{ for all } y \in Y \}$ for a subspace $Y$ of vector space $U$.  I'm really not sure how to start this problem. Any advice would be great! How to remove or hide the GRUB boot menu? Recently I decided to use only Ubuntu and there is no Windows in my laptop. When I turn on my laptop the GRUB menu is showing but I don't need to choose OS anymore.   How can I remove or hide this? And after removing this how could I access to recovery mode? Pages: How to put a word between horizontal rules How can I make something that looks like this?  --------   Text   ---------  where the horizontal rules extend to the margin on either side? Diplomacy Attacking a Territory as they move If I convince Turkey, to move Army Bul to Gre, would I be able to send Army Ser to Bul and take the area? I would like to know how can I customize the Ubuntu installer NOT customize Ubuntu, I just want to modify the installer.  We have a large environment here with lots of developers and since we don't use Windows, I want to customize the installer to automatically set the timezone to NYC, the keyboard layout to English USA, put the company logo in the installer etc...