• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

help with programing

 
rick dog
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am trying to put spaces in a string where 123456 would become 1 2 3 4 5 6
 
Matt Cartwright
Ranch Hand
Posts: 152
Linux VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
well, depends on how those numbers are provided....

I basically can think of two ways doing it:






hope that helps
Matt
 
Henry Wong
author
Marshal
Pie
Posts: 21192
81
C++ Chrome Eclipse IDE Firefox Browser Java jQuery Linux VI Editor Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

I am assuming that this is a homework problem, so... what have you done so far? and what issues have you run into?

Henry
 
Matt Cartwright
Ranch Hand
Posts: 152
Linux VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sorry Rick, you said String. I didn't read carefully enough.
What about a loop and charAt() ?

I sure do have a solution for that.

So, is it homework?
 
Maneesh Godbole
Saloon Keeper
Posts: 11066
13
Android Eclipse IDE Google Web Toolkit Java Mac Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
rick dog wrote:

Please check your private messages for an important administrative matter
 
Campbell Ritchie
Sheriff
Pie
Posts: 49380
62
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You should always use a thread subject which tells us what your question is.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic