Ovo je moj kod, i radi ali u ispisu prikazuje 1.#QNAN ???
#include<stdio.h>
#include<conio.h>
#include<iostream>
#include<string>
using namespace std;
class STRING{
public:
char c[50];
float LENGHT();
float FIND();
float EMPTY();
float INSERT();
float COMPARE();
};
float STRING::LENGHT()
{
return strlen(c);
}
float STRING::EMPTY()
{
if(c[0]=='\0') cout<<"String je prazan"<<endl;
cout<<"String nije prazan"<<endl;
}
float STRING::INSERT()
{
c[2]='s';
cout<<"Nova rijec je: "<<c;
}
int main()
{
STRING S;
cout<<"Unesite rijec: ";
cin.get(S.c,50);
cout<<"Rijec je: "<<S.c<<endl<<endl;
cout<<S.LENGHT()<<endl<<endl;
cout<<S.EMPTY()<<endl<<endl;
cout<<S.INSERT()<<endl<<endl;
getch();
}