What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Skype & Technology » Tech Talk » [Solved] Error on Dev-C++

[Solved] Error on Dev-C++
Author: Message:
Chancer
Senior Member
****

Avatar

Posts: 648
Reputation: 7
35 / Male / Flag
Joined: May 2005
Status: Away
O.P. [Solved] Error on Dev-C++
Hey!
I'm on university now, and I'm gonna learn C.
So I downloaded Dev-C++ and accessed my school's tutorial.

Here is the code:

code:
#include <stdio.h>

int main()
{
  int n, par, impar, num;
 
  printf("Digite o tamanho da sequencia: "); /* mostra mensagem na tela  */
  scanf("%d", &n);                           /* le informacao do teclado */ 

  par   = 0;
  impar = 0;
  cont  = 0;
  while (cont < n)
    {
      printf("Digite o %do. numero: ", cont+1);
      scanf("%d", &num);
      if (num%2 == 0) par = par + 1;
      else impar = impar + 1;
      cont = cont + 1;
    }
 
  printf("A sequencia e' formada por %d numeros pares e %d impares.\n\n",
         par,impar)

  return 0;
}

Actually it's not about the code, cuz it's correct. But when I click "compile", the program can't do this and show me "[Build Error] [main.o] Error 1".

Do you have any idea about it?

Edit: I was looking for other tutorials, and it seems to happen to everyone I try.

This post was edited on 03-02-2008 at 11:56 PM by Chancer.
02-29-2008 12:09 AM
Profile E-Mail PM Find Quote Report
« Next Oldest Return to Top Next Newest »

Messages In This Thread
[Solved] Error on Dev-C++ - by Chancer on 02-29-2008 at 12:09 AM
RE: Error on Dev-C++ - by Naruto-SR on 02-29-2008 at 12:34 AM
RE: Error on Dev-C++ - by Chancer on 02-29-2008 at 05:44 PM
RE: Error on Dev-C++ - by Chancer on 03-02-2008 at 07:12 PM
RE: Error on Dev-C++ - by Mike on 03-02-2008 at 08:13 PM
RE: Error on Dev-C++ - by Chancer on 03-02-2008 at 11:40 PM
RE: Error on Dev-C++ - by vikke on 03-02-2008 at 11:53 PM
RE: Error on Dev-C++ - by Chancer on 03-02-2008 at 11:56 PM


Threaded Mode | Linear Mode
View a Printable Version
Send this Thread to a Friend
Subscribe | Add to Favorites
Rate This Thread:

Forum Jump:

Forum Rules:
You cannot post new threads
You cannot post replies
You cannot post attachments
You can edit your posts
HTML is Off
myCode is On
Smilies are On
[img] Code is On