Why can't I call a template base class constructor with a const_iterator?
Where and why do I have to put the "template" and "typename" keywords?
How well will WCF scale to a large number of client users? Does anyone have any experience with how well web services build with Microsoft's WCF will scale to a large number of users?  The level I'm thinking of is in the region of 1000+ client users connecting to a collection of WCF services providing the business logic for our application, and these talking to a database - similar to a traditional 3-tier architecture.   Are there any particular gotchas that have slowed down performance, or any design lessons learnt that have enabled this level of scalability? Best resources to learn bash scripting? How to compute prediction bands for non-linear regression? Real Analysis: Continuity of a Composition Function Suppose $f$ and $g$ are functions such that $g$ is continuous at $a$, and $f$ is continuous at $g(a)$. Show the composition $f(g(x))$ is continuous at $a$.  My idea: Can I go straight from definition and take $\delta=\min\{\delta_1,\delta_2\}$, where $\delta_1$ is used for the continuity of $g$ at $a$ and $\delta_2$ is used for f being continuous at $g(a)$. In my proof I just treat $g(a)$ as a point when referring to the composition. So it goes like this:  Proof: Given $\epsilon&gt;0$, take $\delta=\min\{\delta_1,\delta_2\}$. Then $0&lt;|x-g(a)|&lt;\delta$ which implies $|f(g(x))-f(g(a))|&lt;\epsilon$. Martingale formulation of Bellman's Optimality Principle From David Williams' Probability with Martingales     Related question:   What I tried: For no 2, if $\ln Z_n - n \alpha$ is a supermartingale, then for $m &lt; n$, $$E[\ln Z_n - n \alpha | \mathscr F_m] \le \ln Z_m - m \alpha$$ $$ \to E[\ln Z_N - N \alpha | \mathscr F_0] \le \ln Z_0 - 0 \alpha$$ $$ \to E[\ln Z_N - N \alpha] \le \ln Z_0$$ $$ \to E[\ln \frac{Z_N}{Z_0}] \le N \alpha$$ Is that right?  For no 1, for $m &lt; n$, $$E[\ln Z_n - n \alpha | \mathscr F_m] = E[\ln Z_n | \mathscr F_m] - n \alpha$$ $$ = E[\ln \frac{Z_n}{Z_0} | \mathscr F_m] - n \alpha + \ln Z_0$$ $$ = E[\ln \frac{Z_n}{Z_{n-1}} | \mathscr F_m] + ... + E[\ln \frac{Z_{m+1}}{Z_{m}} | \mathscr F_m]$$ $$+ \ln \frac{Z_m}{Z_{m-1}} + ... + \ln \frac{Z_{1}}{Z_{0}} - n \alpha + \ln Z_0$$ Note that $$Z_n - Z_{n-1} \le |Z_n - Z_{n-1}| \le C_n |\epsilon_n - \epsilon_{n-1}| \le 2C_n \le 2Z_{n-1}$$ Also, I think $$\ln \frac{Z_n}{Z_{n-1}} \le |Z_n - Z_{n-1}|$$ Hence we have $$E[\ln \frac{Z_n}{Z_{n-1}} | \mathscr F_m] + ... + E[\ln \frac{Z_{m+1}}{Z_{m}} | \mathscr F_m]$$ $$+ \ln Z_m - n \alpha$$ $$\le E[2Z_{n-1} | \mathscr F_m] + ... + E[2Z_{m} | \mathscr F_m]$$ $$+ \ln Z_m - n \alpha$$ $$= 2(E[Z_{n-1} | \mathscr F_m] + ... + E[Z_{m} | \mathscr F_m])$$ $$+ \ln Z_m - n \alpha$$ One thing to do would be to show that $$2E[Z_{n-1} | \mathscr F_m] + ... + 2E[Z_{m} | \mathscr F_m] \le (n-m) \alpha$$ possibly by showing that $2E[Z_{\{\cdot\}} | \mathscr F_m] \le \alpha$ How would I do that? Something else: $$E[\ln \frac{Z_n}{Z_m} | \mathscr F_m] + \ln Z_m - n \alpha$$ $$ \le E[|Z_n - Z_m| | \mathscr F_m] + \ln Z_m - n \alpha$$ $$ \le E[2Z_m | \mathscr F_m] + \ln Z_m - n \alpha$$ $$ \le 2Z_m + \ln Z_m - n \alpha$$ Now $2Z_m \le (n-m) \alpha?$ We have $$2Z_m = 2\sum_{k=1}^{m} C_k(\epsilon_k - \epsilon_{k-1})$$ $$\le 2\sum_{k=1}^{m} Z_{k-1}$$ I'm not quite sure how to show that $$2\sum_{k=1}^{m} Z_{k-1} \le (n-m)\alpha$$ if that's even true. How can/else can I approach this problem?  For no 3, no idea. Any hints? I think it has something to do with a stopping time. Might we have to use the ff lemma (red box):    ? Sum of two closed sets in $\mathbb R$ is closed? Is there a counterexample for the claim in the question subject, that a sum of two closed sets in $\mathbb R$ is closed? If not, how can we prove it?  (By sum of sets $X+Y$ I mean the set of all sums $x+y$ where $x$ is in $X$ and $y$ is in $Y$)  Thanks! Windows executables are started with archive manager I have Wine installed and several Windows applications installed there run fine, if I start them using the right mouse menu "Open with Wine program loader". But if I try starting an .exe file by just double clicking instead, the archive manager tries to open the executable.  How do I fix that?  And something like a bonus question as a former Windows user: Can this be done easily for a single file I currently see in the file manager (similar to the "Open with..." context menu in Windows) and for many file types together (like in Windows, using the menu "Folder settings" in the Explorer)? When writing (a blog post, script, etc..) what is the proper way to indicate two or more instances of a single letter? For instance, in Monty Python's Bookshop Sketch:     C: I wonder if you might have a copy of "Rarnaby Budge"?      P: No, as I say, we're right out of Edmund Wells!      C: No, not Edmund Wells - Charles Dikkens.      P: (pause - eagerly) Charles Dickens??      C: Yes.      P: (excitedly) You mean "Barnaby Rudge"!      C: No, "Rarnaby Budge" by Charles Dikkens.  That's Dikkens with two Ks, the      well-known Dutch author.      P: (slight pause) No, well we don't have "Rarnaby Budge" by Charles Dikkens      with two Ks, the well-known Dutch author, and perhaps to save time I      should add that we don't have "Karnaby Fudge" by Darles Chickens, or      "Farmer of Sludge" by Marles Pickens, or even "Stickwick Stapers" by Farles      Wickens with four M's and a silent Q!!!!!  Why don't you try W. H. Smith's?      C: Ah did, They sent me here.   I had always believed that plural never uses an apostrophe before the 's' (it's only used for possession), but I have rarely seen in written material the format "four Ms". (On a side note, whoever wrote  also used "two Ks".)  On a side note, and perhaps this should be a separate question, if a Compact Disc is a CD, then two Compact Discs would be two CDs right? (I see "CD's" written everywhere) Suppose $f: \mathbb{R} \to \mathbb{R}$ is a continuous function which is 1-1, then does $f$ map Borel sets onto Borel sets? Getting / setting file owner in C# How do you easily horizontally center a  using CSS? I'm trying to horizontally center a &lt;div&gt; block element on a page and have it set to a minimum width. What is the simplest way to do this? I want the &lt;div&gt; element to be inline with rest of my page. I'll try to draw an example:  page text page text page text page text page text page text page text page text                -------                | div |                ------- page text page text page text page text page text page text page text page text Disable chat migration notification if one of the users has insufficient rep? How to find the kth largest element in an unsorted array of length n in O(n)? I believe there's a way to find the kth largest element in an unsorted array of length n in O(n).  Or perhaps it's "expected" O(n) or something.  How can we do this? Simple Hadamard Circuit gives incorrect results? Brand new disk brakes are barely stopping the bike Finding $ \int^1_0 \frac{\ln(1+x)}{x}dx$ There is supposed to be a clean solution to the integral below, maybe involving some symmetry $$ \int^1_0 \frac{\ln(1+x)}{x}dx$$ I have tried integration by parts as followed: $\ln(x+1)=u$ ,$\frac{1}{x+1} dx = du$ and also $\frac{1}{x}dx=dv$, $\ln(x)=v$. Then, the integral becomes $$\int^1_0 \frac{\ln(1+x)}{x}dx=- \int^1_0 \frac{\ln x}{1+x}dx$$ which does not make this easier. I have also tried using the identity $\int_a^bf(x)~dx=\int_a^bf(a+b-x)~dx$. So let $I = \int^1_0 \frac{\ln(1+x)}{x}dx$ and also $I = \int^1_0 \frac{\ln(2-x)}{1-x}  $. Then $$2I= \int^1_0 \ln(1+x)+\ln(2-x)$$ which is not any easier, either. Any ideas? :) In how many different ways can you split $10$ people into two groups of $5$ people? In how many different ways can you split $10$ people into two groups with the same amount of people?  My attempt: Since the order in which you choose someone doesn't matter, I chose to calculate the combinations: $10 \choose 5$ I am executing my ./shell.sh which contains   eval "$(pyenv init -)" pyenv shell 3.8.2   But nothing happens. If i run this code in bash manually it works fine and shell version of python switches from 2.7.10 to 3.8.2.  I am in the right directory and I gave the .sh file execution permissions. $16$ rooks on a chess board. Place $8$ pairwise non-attacking white rooks and black rooks on a $8\times8$ chess board. If one can swap rows and columns, is it possible for the black rooks to take the initial position of the white rooks and vice versa?  My attempt:  Let the rows be $a_1,a_2,...,a_8$ and columns $b_1,b_2,...,b_8$. If there are white rooks at ($a_i$,$b_j$) and ($a_j$,$b_a$) as well as black rooks at ($a_i$,$b_i$) and ($a_j$,$b_j$), then we can reduce it to a $2\times2$ and a $6\times6$.   I don't know what to do next. Any help appreciated. What is going on in front of and behind a fan? Why is it that when you drop paper behind a fan, it drops, and is not blown/sucked into the fan, whereas if you drop paper in front of a fan, it is blown away?