title: How to Properly set an integer value in NSDictionary?
body: <p>The following code snippet:</p>
  
  <pre><code>NSLog(@"userInfo: The timer is %d", timerCounter);
  
  NSDictionary *dict = [NSDictionary dictionaryWithObject:[NSNumber numberWithInteger:timerCounter] forKey:@"timerCounter"];
  
  NSUInteger c = (NSUInteger)[dict objectForKey:@"timerCounter"];
  NSLog(@"userInfo: Timer started on %d", c);
  </code></pre>
  
  <p>produces output along the lines of:</p>
  
  <pre><code>2009-10-22 00:36:55.927 TimerHacking[2457:20b] userInfo: The timer is 1
  2009-10-22 00:36:55.928 TimerHacking[2457:20b] userInfo: Timer started on 5295968
  </code></pre>
  
  <p>(FWIW, timerCounter is a NSUInteger.)</p>
  
  <p>I'm sure I'm missing something fairly obvious, just not sure what it is.</p>