Code Newbie
News     Forums     Search     Members     Sign Up    

My Code Newbie
Username

Password

Articles/Snippets
ASP Classic
ASP.NET
C
C#
C++
HTML / CSS
Java
Javascript
Linux / BSD
Perl
PHP
Python
Ruby
SQL
VB 6
VB.NET

C.N. Friends
  Planet Rome

Link to Us!
Code Newbie
  Code Newbie
    forums
Old 10-31-2005, 06:59 AM   #1 (permalink)
SweetOne
Registered User
 
Join Date: Oct 2005
Posts: 6
SweetOne is on a distinguished road
program printing help

I can't get any output.

please help
Code:
#include <stdio.h>

int ReadData (int iNum);
int CalculateSum (int AnalyticalScore, int QuantitativeScore);
int PrintReport (int StudentID, int AnalyticalScore, int QuantitativeScore, int SumOfScores);


main ()
{
  int StudentID=999;
  int AnalyticalScore=999;
  int QuantitativeScore=999;
  int SumOfScores=999;
  int iNum=0;
  int i;
   for(i=1;i<=iNum;i++)
  {
    int ReadData(int iNum)
    {
      printf("Please enter the number of students: ");
      scanf("%d", &iNum);
    }

    int CalculateSum(int AnalyticalScore, int QuantitativeScore)
   {
     SumOfScores=AnalyticalScore+QuantitativeScore;
   }

   int PrintReport(int StudentID, int AnalyticalScore, int QuantitativeScore, int SumOfScores)
  {
     printf("Student ID: ", &StudentID);
     printf("Analytical Score: ", &AnalyticalScore);
     printf("Quantitative Score: ", &QuantitativeScore);
     printf("Sum of Scores: ", &SumOfScores);
  }
 }
}

Last edited by redhead; 10-31-2005 at 08:39 AM.
SweetOne is offline   Reply With Quote
Old 10-31-2005, 08:40 AM   #2 (permalink)
redhead
Newbie
 
redhead's Avatar
 
Join Date: Jun 2002
Location: Denmark
Posts: 1,709
redhead is on a distinguished road
You do know that function definitions should be left out of function scopes ??
__________________
Don't worry Ma'am, We're university students, We know what We're doing.
-----
If you pull the pin, Mr.Grenade would no longer be your friend.
-----
01000111 01101111 00100000 01000011 00100000 00100001
redhead is offline   Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Printing freesoft_2000 Java 0 11-27-2004 11:19 AM
C++ Deadlock Detection Program Help... coolsc81 Standard C, C++ 2 10-26-2004 06:14 AM
Help on starting new program B00tleg Standard C, C++ 21 10-17-2004 12:58 PM
Problem printing, please help me laurence10 Java 0 03-11-2003 04:26 PM


All times are GMT -8. The time now is 01:22 PM.


Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.0.0 RC8





Copyright © 2000-2008, Milano Interactive
Web Hosting provided by Portal 360 Web Hosting