Search:
Type: Posts; User: egawtry
Search :
Search took 0.03 seconds.
February 29th, 2012 02:27 PM
Basic Bubblesort: (this should be in your book somewhere)
int i, j;
for(i = 0; i < 6; ++i)
for(j = i+1; j < 6; ++j)
{
if( list[i] > list[j] )
February 29th, 2012 12:01 PM
Okay, looks like a standard array. For your program, do the bubblesort like I hope is in your textbook; then you will have:
12 17 30 45 51 62
Do a for() loop, adding every other one.
Ex:...
February 29th, 2012 11:08 AM
What is the list?
This seems to be an exercise of for() loops. First to sort the array, then to add every other number.
Hints: i += 2 for the for(), and look up bubblesort for the sort.
...
February 15th, 2012 10:18 AM
Just an idea - are you compiling UNICODE or MBCS?
MBCS will use local code pages and mess up like you are seeing.
January 24th, 2012 11:37 PM
You need to post more information.
1. Is it a regular DLL or MFC?
2. Does it access any database, if so, do you share it?
3. What type of interface are you using.
January 22nd, 2012 12:50 PM
I hardly have contempt for higher education, my current work on my masters demonstrates that. I DO have contempt for how CS is taught these days. Graduates leave college with all these bright...
January 20th, 2012 01:14 PM
I don't agree. That is the way to get a good corporate job, not necessarity be a good programmer. I have worked for corporations and interviewed many prospective new-grads. They were so full of...
January 18th, 2012 05:53 PM
I have written several whitepapers on "Rootbeer" functions (A&W functions) for my work. If anyone is interested, I can dig them up and repost.
-Erik
January 18th, 2012 11:55 AM
Convert the UNICODE string to MBCS, then insert it.
size_t size;
CHAR szString[256];
wcstombs_s(&size, szString, _countof(szString), (LPCWSTR)strWText, strWText.GetLength());
//nIndex =...
January 17th, 2012 11:22 PM
Are you sure you don't mean VB6? Things are not control based in C.
What you need is to take a look at CSocket and CListen if you are using MFC, and socket(), connect(), and listen() if you are...
January 4th, 2012 06:12 PM
January 4th, 2012 05:58 PM
But the LIB file isn't distributed to end users.:ehh:
January 4th, 2012 05:33 PM
The only reason I have ever seen, in spite of the "size" issue, is for people who are paranoid about security. It removes all possibility of easily hacking the DLL without having to disassemble it. ...
January 4th, 2012 01:49 PM
There are quite a few parameters that can be added to a DEF export, most of them unnecessary.
The NONAME is for the paranoid, I assume that Igor did it out of habit.:)
The most commonly used...
January 4th, 2012 01:30 PM
There are 3rd party programs to do this, but most people just dynamically export functions with _dllexport if they are too lazy to use a DEF file.
That is why I ALWAYS use a DEF file.
...
January 4th, 2012 01:25 PM
True, it would link, but then immeadiately do the function missing popup when run. Sorry for the confusion, I was thinking of a special case.
-Erik
January 4th, 2012 10:28 AM
On the DLL end:
1. Functions are exported by name. If no number is assigned to it, then one is arbitrarity assigned.
2. Functions can be exported by _dllexport, but if they are C functions, they...
January 2nd, 2012 12:35 PM
Note 1: You are already filling the arrays in the declaration. You don't need to implicitly call the function.
Note 2: Because you are calling srand() both times with time(), which has a one...
January 1st, 2012 11:27 AM
Have you tried moving the using directives to after the includes?
Where is the index to kartSayilar on the third line in the for loop? I think you want:
srand(int(time(NULL))); ...
December 31st, 2011 12:49 PM
Try passing references:
double hatsize(double &h, double &w, double &a, double &hs)
{
cout<< "Enter your height in inches: ";
cin>> h;
cout<< "Enter your weight in pounds: ";
cin>> w;...
December 29th, 2011 12:57 PM
Police??!?:eek:
I also hate it when someone is peering over my shoulder. If it is my boss, I just grit my teeth and bear it. Anyone else, I tell them to move. One of my main pet peeves.
As...
December 26th, 2011 07:28 PM
I don't, except that this isn't Facebook.:eek:
====================
As for your question, what I am saying is that a good programmer needs to understand the fundamentals. It is impossible to...
December 26th, 2011 03:24 PM
I don't get what his/her parents have to do with it either.
What don't you get?
-Erik
December 26th, 2011 01:34 PM
Sounds like you are using MBCS code and UNICODE flags.
WM_SETTEXT also comes in rootbeer versions WM_SETTEXTA and WM_SETTEXTW.
Try specifying which one.
-Erik
December 26th, 2011 12:28 PM
The way to do that is understand how everything works. Not just the top level functions and operations, but how they actually work.
For Example: (this is VERY basic, but a simple example)
C++...
Click Here to Expand Forum to Full Width