Article View: be.comp.programming
Article #9384Splitten van een string
From: Christof Laeremans
Date: Sun, 28 Apr 2002 13:38
Date: Sun, 28 Apr 2002 13:38
26 lines
1496 bytes
1496 bytes
Hallo,
Even een klein probleem waar ik niet uitgeraak.
Ik heb een string nl. VOLVO_OPEL_BMW ( _ staat voor een spatie)
Hoe kan ik deze nu splitsen in
VOLVO
OPEL
BMW
Deze string staat in een file dus heb ik al het volgend gedaan
Ifstream infile
Infile.open("auto.txt")
Infile.getline(wagen,100,'\n');
En dan begint het natuurlijk, deze string gaan splitsen.
Weet er soms iemand een algorithme of een functie dit dat kan doen ?
Mvg,
Christof Laeremans
Technical Details
Message-ID:
<B8F1C801.259E%christof_laeremans@hotmail.com>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-06!supernews.com!news.tele.dk!small.news.tele.dk!195.238.2.15!skynet.be!skynet.be!news.be.wanadoo.com!news.wanadoo.be!not-for-mailShow Full Headers
Complete Article Headers
X-Google-Language: DUTCH,ASCII-7-bit X-Google-Thread: fcea4,f3dea7aa33b64890,start X-Google-Attributes: gidfcea4,public X-Google-ArrivalTime: 2002-04-28 06:38:50 PST Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-06!supernews.com!news.tele.dk!small.news.tele.dk!195.238.2.15!skynet.be!skynet.be!news.be.wanadoo.com!news.wanadoo.be!not-for-mail From: Christof Laeremans <christof_laeremans@hotmail.com> Newsgroups: be.comp.programming Subject: Splitten van een string Date: Sun, 28 Apr 2002 15:38:41 +0200 Organization: Wanadoo Belgium Lines: 27 Message-ID: <B8F1C801.259E%christof_laeremans@hotmail.com> NNTP-Posting-Host: adsl-140-105.wanadoo.be Mime-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit X-Trace: sinclair.be.wanadoo.com 1020001123 1553109 213.177.140.105 (28 Apr 2002 13:38:43 GMT) X-Complaints-To: abuse@wanadoo.be NNTP-Posting-Date: Sun, 28 Apr 2002 13:38:43 +0000 (UTC) User-Agent: Microsoft-Entourage/10.0.0.1309