[an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] (none) [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive] (none) [an error occurred while processing this directive] [an error occurred while processing this directive] [an error occurred while processing this directive][an error occurred while processing this directive]
 
[an error occurred while processing this directive] [an error occurred while processing this directive]
Skåne Sjælland Linux User Group - http://www.sslug.dk Home   Subscribe   Mail Archive   Forum   Calendar   Search
MhonArc Date: [Date Prev] [Date Index] [Date Next]   Thread: [Date Prev] [Thread Index] [Date Next]   MhonArc
 

Re: [CPROG] _itoa



Jeg ved íkke helt hvad den skal bruges til, men der er en funktion der kan
gøre det større og det er at ud bygge den med denne fra Visual C++

grow()                // Hvor str er størrlsen af arrayet
{
 int* tmp= new int [str*2];
 for (int h=0;h<str;h++)
 tmp[h]=liste[h];
 delete[]liste;
 liste=tmp;
 str=str*2;

}
----- Original Message -----
From: Sune Fischer <sslug@sslug>
To: <sslug@sslug>
Sent: Thursday, June 10, 1999 6:47 PM
Subject: [CPROG] _itoa


>
> Et lidt fjollet spørgsmål, men jeg skal bruge den inverse funktion til
> atoi. Jeg ved ikke hvad den hedder, i win hedder den _itoa og
> konverterer altså en integer til streng. Kan ikke finde den under man
> pages.
>
> Er der nogen meninger om hvad der er det bedst valg af disse to
> metoder:
>
> char* buffer;
> ....
> buffer=new char[x];
> ....
> delete [] buffer;
>
> og den anden metode med calloc:
>
> buffer = (char *)calloc( x, sizeof( char )
> ..
> free( buffer );
>
> Findes der en måde at reskalere arrayen på uden først at slette den og
> oprette den igen?
>
> Sune
>
> ===
> MVH.  Bs.c. scient. Sune Fischer
> a.k.a. Ruleren a.k.a. El Supremo a.k.a. Slageren
> a.k.a. Meyer Mesteren a.k.a. Lord Fischer a.k.a Don Superior
> a.k.a. El Rulér a.k.a. Magtfaktoren a.k.a. The Mighty One
> a.k.a. HWR4E
> _________________________________________________________
> Do You Yahoo!?
> Get your free @yahoo.com address at http://mail.yahoo.com
>



 
Home   Subscribe   Mail Archive   Index   Calendar   Search

 
 
Questions about the web-pages to <www_admin>. Last modified 2005-08-10, 20:07 CEST [an error occurred while processing this directive]
This page is maintained by [an error occurred while processing this directive]MHonArc [an error occurred while processing this directive] # [an error occurred while processing this directive] *