by Yada on April 22, 2010
I find Tim Hortons coffee too hot to hold especially while drinking and driving. Yes, I drink coffee and drive. It’s not against the law.
When I make my coffee order at Tim Horton’s drive thru in the morning I would ask for ‘Double Cup’. The optimum brewing temperature of coffee is 90′c which is pretty much close to boiling. This is too hot for me to hold.
I often wondered why Tim Horton’s doesn’t have coffee sleeves. Today I think I figured out why.
IT’S NOT COST EFFECTIVE. It’s better to employ double cup. Take a look at this price chart at a restaurant supplies store.

Look at the price of Coffee sleeves. It’s is $37.99 for a box of 1000s. Take a look at the price of 1000s cups. It around the same price! Therefore, if Tim Hortons have coffee sleeves in the store probably about 25%* of the patrons would use it. Currently, probably about 5% of the patrons would ask for Double Cup. Hence, it’s better to not use sleeves and let the customers ask for Double Cup.
*number is educated guess. When I worked at Starbucks, 95% of patrons use coffee sleeves. 25% is a low end guess.
by Yada on March 18, 2010
CRU on TSX.
Cup and Handle pattern has been forming since lat November 2009, about 4 months.

Measured Target
Measure the height from the right cup lip to the lowest valley then multiply by the above “percentage meeting price target.”
Cup and Handle pattern setups
- Right lip resistance is at $0.41.
- 4 months long
- handle took 2 weeks to form
- Right lip is higher then left lip
- U shaped
- small volume going down the handle
- large volume going up the handle
- 200 day Moving Average is at .40 which is right at the resistance. Crossing MA200 is another bullish signal.
Measured target price is $1.11 – $1.51
$0.11 –> $0.41 = 271%
From the bottom of the cup to the height right cup lip: $0.11 –> $0.41 (272%)
The resistance line for breakout is $0.41. There the target price is $0.41 (272%) = $1.52.

by Yada on March 10, 2010
I wrote a quick php script to download all the stock charts from a defined list, make web service calls to stockcharts.com and display the picture. A quick way to see many charts at a glance.
http://yadakhov.com/dow30
Here’s one for the S&P TSX 60 which has the largest 60 Canadian companies.
http://yadakhov.com/tsx60
1. Gmail doesn’t look at ‘period’ in the email.
johnsmith@gmail.com
john.smith@gmail.com
j.o.h.n.smith@gmail.com
Is all the same emails. Email sent to any of the address will be forwarded to the same email account.
This is a neat way to sign up for multiple accounts at some other service that requires unique email. I found that out on my own because I have a period in my email and saw some email coming to me without the period.
2. The second trick, I read on lifehacker is to use the plus sign trick.
Example: You could use
johnsmith+nytimes@gmail.com for nytimes.com
johnsmith+freestuff@gmail.com for freestuff.com
Gmail will automatically remove everything including the plus sign.
by Yada on February 24, 2010
A developer was trying to compute the average of the first 100 records with LIMIT:
SELECT
avg(con_hits) as avg_hits
FROM
content
WHERE
con_type = 1
AND con_posttime < $twelve_hrs_ago
AND con_refresh = 0
ORDER BY
con_posttime DESC
LIMIT 100
Can you spot the subtle bug in the above query?
LIMIT is applied to the resultset, after AVG is calculated. The correct way is to use a subselect and apply the aggregate function:
SELECT avg(con_hits) as avg_hits
FROM (
SELECT con_hits
FROM content
WHERE
con_type = 1
AND con_posttime < $twelve_hrs_ago
AND con_refresh = 0
ORDER BY con_posttime DESC
LIMIT 100
) x;