How i print variable from another NSString?

Discussion in 'iOS Programming' started by Xtrician, Dec 4, 2011.

  1. Xtrician, Dec 4, 2011
    Last edited by a moderator: Dec 5, 2011

    Xtrician macrumors newbie

    Joined:
    Jan 12, 2011
    #1
    Hello,
    What i mean is,
    For Example:
    Code:
    NSString *s = @"Alex";
    NSString *s2 = @"Hi [s] how are you?";
    
    NSLog(s);
    NSLog(s2);
    Here is the output i want:
    Alex
    Hi Alex how are you?

    What is the correct syntax and the easy way to do this?
    Thanks.
     
  2. subsonix macrumors 68040

    Joined:
    Feb 2, 2008
    #2
  3. Xtrician thread starter macrumors newbie

    Joined:
    Jan 12, 2011
  4. jnoxx macrumors 65816

    jnoxx

    Joined:
    Dec 29, 2010
    Location:
    Aartselaar // Antwerp // Belgium
    #4
    Maybe pickup a book on basic programming in Xcode IDE and Objective-C Environment, no personal offense, but if every1 will start off with asking such questions, the forum will be a bit flooded :)
     

Share This Page