Win a copy of TDD for a Shopping Website LiveProject this week in the Testing forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Frits Walraven
Bartenders:
  • Piet Souris
  • Himai Minh

GC Doubts

 
Ranch Hand
Posts: 344
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
From web page


Pls pls expalain.. very confusing..
[ December 12, 2006: Message edited by: Micheal John ]
 
Ranch Hand
Posts: 7729
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Have you read the answer here? If so, then what do you not understand?
 
Micheal John
Ranch Hand
Posts: 344
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
For me the output is d. A1A2A3A1A1A2A3.

by calling A other():A1A2A3A1
by calling finalize: A1A2A3

but, they given the output as a,c,d,e...how..?
a.A1A2A3A1
c.A1A2A3A1A2A3
d.A1A2A3A1A1A2A3
e.A1A2A3A1A3A2A1

Why can't we choose only d?

and also in the above pgm, if I replaced the for loop with infinite loop, then A1A2A3A1 this sequence will print infinitely..correct?
[ December 12, 2006: Message edited by: Micheal John ]
 
knowledge is the difference between drudgery and strategic action -- tiny ad
Free, earth friendly heat - from the CodeRanch trailboss
https://www.kickstarter.com/projects/paulwheaton/free-heat
reply
    Bookmark Topic Watch Topic
  • New Topic