Search Results

Showing results 1 to 5 of 5
Search took 0.00 seconds.
Search: Posts Made By: Cybulski ; Forum: C++ and child forums
Forum: C++ May 31st, 2008
Replies: 4
Views: 1,071
Posted By Cybulski
How about casting
int* a = (int*)x;?
Forum: C++ May 21st, 2008
Replies: 4
Solved: Delete Folder
Views: 798
Posted By Cybulski
It lists files, you still need recursively delete directories beginning with deepest path. This calss will be more complex, handling configuration file and multitasking.

DirectoryReader.h:
...
Forum: C++ May 21st, 2008
Replies: 4
Solved: Delete Folder
Views: 798
Posted By Cybulski
You need to empty this folder I guess. That's how Windows works if you noticed.

Right now I am working on file listing class, it places all files in given subdirectory in vector of strings. If you...
Forum: C++ May 19th, 2008
Replies: 12
Solved: string reverse
Views: 4,921
Posted By Cybulski
This way or another, you should use iterators, to avoid exceeding string boundaries.

For example:

string str;
string::iterator iter_str = str.begin();

while(iter_str != str.end())
{...}
Forum: C++ May 17th, 2008
Replies: 12
Solved: string reverse
Views: 4,921
Posted By Cybulski
I don't really want to think at the moment, but I can post you my string reversing piece of code. Safe and elegant.

#include <string>

string str="shankhs";
reverse(str.begin(), str.end());
Showing results 1 to 5 of 5

 


About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC