Created
March 4, 2015 20:42
-
-
Save tywoplenty/c8b22495ead8057fe266 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> | |
<CodeBlocks_project_file> | |
<FileVersion major="1" minor="6" /> | |
<Project> | |
<Option title="insertionsort" /> | |
<Option pch_mode="2" /> | |
<Option compiler="gcc" /> | |
<Build> | |
<Target title="Debug"> | |
<Option output="bin/Debug/insertionsort" prefix_auto="1" extension_auto="1" /> | |
<Option object_output="obj/Debug/" /> | |
<Option type="1" /> | |
<Option compiler="gcc" /> | |
<Compiler> | |
<Add option="-g" /> | |
</Compiler> | |
</Target> | |
<Target title="Release"> | |
<Option output="bin/Release/insertionsort" prefix_auto="1" extension_auto="1" /> | |
<Option object_output="obj/Release/" /> | |
<Option type="1" /> | |
<Option compiler="gcc" /> | |
<Compiler> | |
<Add option="-O2" /> | |
</Compiler> | |
<Linker> | |
<Add option="-s" /> | |
</Linker> | |
</Target> | |
</Build> | |
<Compiler> | |
<Add option="-Wall" /> | |
<Add option="-fexceptions" /> | |
</Compiler> | |
<Unit filename="main.cpp" /> | |
<Extensions> | |
<code_completion /> | |
<envvars /> | |
<debugger /> | |
<lib_finder disable_auto="1" /> | |
</Extensions> | |
</Project> | |
</CodeBlocks_project_file> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# depslib dependency file v1.0 | |
1420758066 source:c:\users\taiwo\desktop\grading program\insertionsort\main.cpp | |
<iostream> | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?> | |
<CodeBlocks_layout_file> | |
<ActiveTarget name="Debug" /> | |
<File name="main.cpp" open="1" top="1" tabpos="1" split="0" active="1" splitpos="0" zoom_1="0" zoom_2="0"> | |
<Cursor> | |
<Cursor1 position="523" topLine="6" /> | |
</Cursor> | |
</File> | |
</CodeBlocks_layout_file> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <string> | |
using namespace std; | |
class Tring { | |
int *p_age; | |
string *p_nationality; | |
string *p_name; | |
public: | |
Tring () : p_name (0){}; | |
Tring (string&n): p_name(&n){}; | |
void parallellist (); | |
~Tring (); | |
}; | |
void Tring::parallellist (){ | |
for (unsigned int i =0; i<p_name->size(); i++){ | |
int number = i+1; | |
char * p_char = &p_name; | |
cout << number << " " << *p_char << endl; | |
&p_name+=1; | |
} | |
} | |
void enterstring(); | |
int main () { | |
enterstring(); | |
Tring neww(theword); | |
neww.parallellist(); | |
return 0; | |
} | |
void enterstring() { | |
string word; | |
cout << "Enter the name of the plater: " << endl; | |
cin >> word; | |
Tring *ptring = new Tring(word); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment