+ 6
Can anyone help me in doing my mini project for my higher secondary using cpp ( must include files and classes.)????
cpp ALL KINDS OF CODES ARE ACCEPTED CONDITIONS ARE IN THE QUESTION ........
4 Antworten
+ 5
you have try my friend we will try to help u if you try working on code
+ 2
Thanks my dear friend....
+ 2
Can anyone teach me how to make header files ????
+ 2
Thomas Kurian :
header file in cpp are made like this
if your header file is named header.h :
#ifndef HEADER_H
#define HEADER_H
//put all your class and functions prototypes in there. exemple:
class Friend(){
public:
void gethello();
private:
int age;
};
#endif
and that all !
all you have to do is to define your classes and function into your main file or into another .cpp
exemple of a class.cpp file
#include ”header.h"
#include <iostream>
void Friend::gethello{
cout<<hello;}
(if your doing a second .cpp file you need to include the header file in the main too and compile the two .cpp files )