i just changed the
gets(A[i].lastname)
with
cin >> A[i].lastname
and worked perfectly
Thnx for help :)
Type: Posts; User: stam
i just changed the
gets(A[i].lastname)
with
cin >> A[i].lastname
and worked perfectly
Thnx for help :)
Ok the program is done but when it runs and u start give what it asks
Example:
How many athletes; 2 (we give 2)
***Give Athletes Data:
Lastname: Messi
First Jump: 5.6
etc....
Instead of...
Ok guys thnx for help, till now i have done this:
#include <cstdlib>
#include <iostream>
#define MAX_ATHLETES 4
using namespace std;
struct athlete
{
No we haven't done vectors and i don't think we will ^^ (Oi apergies ftaine :P)
Any other way to do it?
Here is what i have done so far...
Beacuse i couldnt put the read section in fuction i leave it in main.(I need to functionize it.. HELP!!!)
I did a search (i think :P) in a function that read all...
We have a structure with the following data
struct athlete
{
char lastname[40];
float p1,p2,p3,p4;
};
that corespond to athletes of "Long Jump" that have been done in a competiton....
Ok and how i am gonna give them the char a want to remove and the string i want to remove multiple spaces.
Its not like common functions.
Please explain i wanna learn something from this thing...
Well right now this code Removes one specific letter from the string we give.
The problem is that i found this func code on google so i don't really understand it(I am very new to this)
I made the...