My code does not run

Employees are due for promotion and bonuses according ti the following criteria
*All employees in ICT, Marketing and Estate Department are due for a bonus.

*However, only employees in ICT department who are junior staff are eligible for promotion and a bonus.

Write a program that allows a user to enter his/her department and status(senior or junior staff) and display whether the user is eligible for a promotion and or bonus.
I think your problem is on line #12.
Well, no wonder why it doesn't work: You have written none. Or you have neglected to show it to us in your post. How can we help you correct your code if you haven't showed it to us? Or were you expecting that someone would just do your homework for you???

Read http://www.cplusplus.com/forum/beginner/1/ before posting. In a nutshell, you must make an effort in order to expect an effort from an expert, potentially. But seriously, read the link before posting.

Oh, and if you decide to post code, please surround it with code tags, like this:

[code]//Code goes here. [/code]
1
2
3
4
5
6
7
8
9
10
11
#include <stdio.h>

int main()
{
    char stuff[200];

    printf("Please enter department and status: ");
    scanf("%s", stuff);
    printf("You have been fired.");
    return 0;
}

Concord. *W*
closed account (zb0S216C)
I see the problem here. You've simply overlooked the missing semi-colon on line 13, just after the std::endl statement. On a side note, you can avoid undefined behaviour by initializing no_of_employees to zero.

Wazzak
Topic archived. No new replies allowed.