Article View: es.comp.os.linux.programacion
Article #14068Re: Expediente X
From: Victor Couce
Date: Sun, 17 Dec 2000 18:16
Date: Sun, 17 Dec 2000 18:16
63 lines
2499 bytes
2499 bytes
Debe se porque te falta el return 0; antes del ultimo corchete. Lo
que ya no se es porque en uno funciona y en otro no.
Salu2.
________________________
Victor Couce -> victorc@linuxfan.com
On Sun, 17 Dec 2000 14:01:29 +0100, "Hugo Garcia Alonso"
<hugogar@QUITA_ESTO.netcom.atodavela.com> wrote:
>-----BEGIN PGP SIGNED MESSAGE-----
>Hash: SHA1
>
>Hola a todos, os mando este pequenyo esqueleto de programa para ver
>si alguien puede ver por que con el cc se niega a compilar, mientras
>que con el g++ compila sin problemas.
>
>Muchas gracias por la ayuda desinteresada
>
>Saludos
>
>
>#include <stdio.h>
>
>#define TAM (1024/sizeof(int)-2) /*Numero de enteros en la cola*/
>
>int array[TAM];
>int meter = 0;
>int sacar = 0;
>
>int almacenar(int valor)
>{
>}
>
>int recuperar(void)
>{
>}
>
>int main()
>{
> printf("Al intentar sacar algo estando vacia dio %d\n", recuperar());
>
> printf("Meto del 0 al 9\n");
>
> int i;
> for(i=0; i<10; i++)
> if(!almacenar(i)) printf("Error al insertar el valor %d\n", i);
>
> printf("El primer elemento es %d\n", recuperar());
>}
>-----BEGIN PGP SIGNATURE-----
>Version: GnuPG v1.0.1e-SuSE (GNU/Linux)
>Comment: For info see http://www.gnupg.org
>
>iD8DBQE6PDe7znOLumltoeoRAmygAJ485waLkDY2ldUeaQKAX2x7Iuh7wwCeNQSk
>9XNFdtnHSJjjiuwRe38j3fw=
>=N8Cj
>-----END PGP SIGNATURE-----
>
>
>
Technical Details
Message-ID:
<3a400228.3931380@news.wanadoo.es>Path:
arc1-ca.pugleaf.net!supernews.google.com!sn-xit-02!supernews.com!nntp-relay.ihug.net!ihug.co.nz!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.skycache.com!Cidera!newsfeed.comtenidos.com!m2newsfeed.uni2.es!m2newsread.uni2.es.POSTED!not-for-mailReferences:
<3a3cc231@filemon.telecable.es>Show Full Headers
Complete Article Headers
X-Google-Language: SPANISH,ASCII-7-bit X-Google-Thread: f86c8,b243c6db34cbd77e X-Google-Attributes: gidf86c8,public X-Google-ArrivalTime: 2000-12-17 10:16:52 PST Path: arc1-ca.pugleaf.net!supernews.google.com!sn-xit-02!supernews.com!nntp-relay.ihug.net!ihug.co.nz!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.skycache.com!Cidera!newsfeed.comtenidos.com!m2newsfeed.uni2.es!m2newsread.uni2.es.POSTED!not-for-mail From: racocanet@yahoo.com (Victor Couce) Newsgroups: es.comp.os.linux.programacion Subject: Re: Expediente X Reply-To: racocanet@yahoo.es Message-ID: <3a400228.3931380@news.wanadoo.es> References: <3a3cc231@filemon.telecable.es> X-Newsreader: Forte Agent .99g/32.339 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Lines: 64 Date: Sun, 17 Dec 2000 18:16:39 GMT NNTP-Posting-Host: 62.36.161.94 X-Complaints-To: abuse@wanadoo.es X-Trace: m2newsread.uni2.es 977076999 62.36.161.94 (Sun, 17 Dec 2000 19:16:39 MET) NNTP-Posting-Date: Sun, 17 Dec 2000 19:16:39 MET Organization: Servidor Usenet News de Uni2/Wanadoo