Optimal Pricing Strategy I have 1 room for rental. I can ask any price. The customers come in sequentially. If the customer has money that is equal to or greater than my price, they will take my room. Otherwise I get nothing. 
Assume customer's money is exponentially distributed with parameter $\lambda=1$, and they are i.i.d, and there are $n=30$ customers in total.
a) Assume your pricing is fixed. what is your optimal price?
b) If you can change your pricing every time you want (i.e., you ask customer 1 for 10 dollars, you can ask customer 2 for 5 dollars, etc). What is your optimal price?

Attempt:
a) For $n$ customers, I will get $p*I_{X_1 >p, OR, X_2>p, OR, X_3>p,......OR,X_n>p}$, where $I$ is the indicator function. Thus, i will have $p*n*exp(-p)$, taking the derivative and set it to 0, I get $p^*=1$.
b) For the adjustable price, let $p_i=$ price that you ask for the $i_th$ customer, then the profit is:
$p_1P(X_1>p_1) + p_2 P(X_1<p_1  \wedge X_2>p_2) + p_3 P(X_1<p_1  \wedge X_2<p_2  \wedge X3>p_3 +) .... $
$= p_1e^{-p1} + p_2(1-e^{-p_1})(e^{-p_2}) +...$ 
 A: We will do $a$ for $n$ customers and call the price $p$.  This will be useful for b  For $a$, the chance you get nothing is the chance none of the $n$ people have that much money.  The chance a given person has that much money is $e^{-p}$, so the chance they do not is $1-e^{-p}$ and the chance nobody has that much is $(1-e^{-p})^n$  You therefore expect to receive $p(1-(1-e^{-p})^n)$.  This is what you should differentiate and set to zero.  Alpha does not find an analytic solution, but finds the maximum to be $2.3738$ at $p \approx 2.81488$  
b is harder.  Clearly as you run trough people you should lower your price.  This means failing with the first person is less costly so you should probably raise your early asking price.  The way to attack it is from the back.  When you see the last person, your expected income is $pe^{-p}$, which has maximum of $\frac 1e$ at $p=1$.  Now that you know that, you can use that to set your price for the next to last person.  Your expected return is $pe^{-p}+(1-e^{-p})\frac 1e$ where the first term is the expected return from the second to last person and the second term is the expected return from the last.  Find the maximum  and that gives your asking price for the next to last.  Keep working backwards.
