Wrox Programmer Forums
| Search | Today's Posts | Mark Forums Read
BOOK: Beginning iOS Game Development
This is the forum to discuss the Wrox book Beginning iOS Game Development by Patrick Alessi ; ISBN: 978-1-1181-0732-4
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning iOS Game Development section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old May 2nd, 2012, 04:27 PM
Registered User
Points: 14, Level: 1
Points: 14, Level: 1 Points: 14, Level: 1 Points: 14, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: May 2012
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default [Modeling a Deck of Cards] question

I am newbie to programming and got stuck at the try it out of the chapter 3, called Modeling a Deck of Cards.
So in the code there is:
Code:
printf(“The first card is %s of %s\n”, deck[0].value, deck[0].suit);
However Xcode didn't like this at all. I assume the code should be
Code:
printf(“The first card is %s of %s\n”, deck[0].name, deck[0].suit);
later when working with loops, there is the same approach:
Code:
for (int i=0; i<52; i++) {
printf(“The card is %s of %s\n”, deck[i].value, deck[i].suit);
}
and it doesn't work for me
Can someone please advise?
Thanks
 
Old May 2nd, 2012, 10:48 PM
Friend of Wrox
Points: 1,671, Level: 16
Points: 1,671, Level: 16 Points: 1,671, Level: 16 Points: 1,671, Level: 16
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Aug 2010
Posts: 298
Thanks: 1
Thanked 62 Times in 60 Posts
Default

This has been addressed in a previous thread
Tracking errata

Bob
 
Old May 3rd, 2012, 01:44 AM
Registered User
Points: 14, Level: 1
Points: 14, Level: 1 Points: 14, Level: 1 Points: 14, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: May 2012
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Oh, I see...I thought I am missing something due to lack of knowledge
Thank you, Bob




Similar Threads
Thread Thread Starter Forum Replies Last Post
Chapter 3, pg 68 - Shuffling the Deck of Cards maconspace BOOK: Beginning iOS Game Development 11 March 11th, 2012 08:28 AM
Many-to-many dimensional modeling boson SQL Server 2000 6 September 22nd, 2006 12:34 PM
Modeling with restrictions on attribute value jacob XML 0 June 3rd, 2005 07:01 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.