Posts
 
Reputation
Joined
Last Seen
Ranked #1K
Strength to Increase Rep
+7
Strength to Decrease Rep
-1
96% Quality Score
Upvotes Received
19
Posts with Upvotes
19
Upvoting Members
16
Downvotes Received
1
Posts with Downvotes
1
Downvoting Members
1
7 Commented Posts
0 Endorsements
Ranked #490
~38.5K People Reached
Favorite Tags
Member Avatar for xxunknown321

Well, String is not string. You have to write it in lowercase. [CODE]void toString();[/CODE] should be: [CODE]void toString(string &target); void Employee::toString(string &target){ target = "Name: " + empName + " / Employee Number: " + empNum + " / Hire Date: " + hireDate; } [/CODE]

Member Avatar for jimmichaels29
0
1K
Member Avatar for BobRoss

Works fine for me. Can you provide how and with what you tested it then it's freezes?

Member Avatar for happygeek
0
1K
Member Avatar for rajeshwari_ib

Hi, first of all storing a BLOB is very bad design. But, it would be like this: [CODE]blob_value = open('image.jpg', 'rb').read() sql = 'INSERT INTO Tab1(blob_field) VALUES(%s)' args = (blob_value, ) cursor.execute (sql, args) connection.commit()[/CODE]

Member Avatar for Gribouillis
0
2K
Member Avatar for josey_matt

like this? [CODE]#include <iostream> #include <fstream> #include <string> using namespace std; //void calculateAverage(); //int calculateGrade(); //void updateFrequency(); int main() { //const int size=10; //int debug=size; string tmp; //int test1[size], test2[size], test3[size], test4[size], test5[size]; ifstream infile; /* for(int i=0;i<size;i++) { test1[i]=0; test2[i]=0; test3[i]=0; test4[i]=0; test5[i]=0; } */ cout<<"Reading from file ''input.txt''..."<<endl; …

Member Avatar for siddiquedu
0
8K
Member Avatar for bman214

[CODE]#include<iostream> // not iostream.h #include <stdio.h> #include <stdlib.h> using namespace std; int main() { //Intro cout << "Welcome to The Final Journey v. 0.0.3 Alpha."<<endl; system("pause"); cout << "You are an adventurer, traveling from town to town, looking for monsters and bold followers."<<endl; cout << "Your homeland is Chosan, a …

Member Avatar for bman214
0
204
Member Avatar for petmol
Member Avatar for l1ttledb

Hi, line 19 prototype, return type is char, line 172 implementation no return type. Changed it to return type char and everybody will be happy :)

Member Avatar for sree_ec
0
272
Member Avatar for Sudo Bash

Some things got messed up it should be like this: main.cpp [CODE]//file1.cpp #include<iostream> #include"file3.h" using std::cout; using std::cin; namespace baz { extern MyClass foobar; } int main() { baz::foobar.setFOO(); baz::foobar.bar(); cout << *baz::foobar.FOO << "\n"; cin.ignore(); return 0; } [/CODE] [CODE] //file3.h namespace baz{ class MyClass { private: int foo; …

Member Avatar for programmersbook
0
3K
Member Avatar for rhum123

Line 39 you should type cast: [CODE] median = (element[(int)(nep/2)] + element[(int)(nep/2-1)]) / 2;[/CODE]

Member Avatar for programmersbook
0
172
Member Avatar for sharensla
Member Avatar for Tech B
Member Avatar for tunde011

HI, first of all, it's not a good idea to store the mail plain, better generate a crypt key, and same the email on your side with the key. Anyway it would be like this: [CODE] <form method="post" action="formposting.php"> <input type="text" name= "title" size="22"> <input type="text" name= "email" size="22"> <?php …

Member Avatar for vaultdweller123
0
112
Member Avatar for Pramirez3
Member Avatar for sidra 100

line 6: should be: [CODE]void merge(char[],int, char[], int,char[],int*);[/CODE] better: [CODE]void merge(char[],int, char[], int,char[],int&);[/CODE] [CODE]//----------merging----------- void merge (char array1[],int size1, char array2[],int size2, char c[],int &size ) { for (int k=0;k< size1;k++) { c [k] =array1[k]; } for (int k=0;k<size2;k++) { c [size1+k] = array2[k]; size=size1+size2; } } [/CODE] Did you …

Member Avatar for sidra 100
0
99
Member Avatar for codecutie

Line 24.25. is kind of the same? I you pop you need to release memory and check if you are and the end or will will get an segv. And if you are in C++ a class would just cool.

Member Avatar for programmersbook
0
134
Member Avatar for afireinside7710

Hi! ftp.sendcmd is only for FTP commands. Google gave me this: [url]http://commandline.org.uk/python/sftp-python-really-simple-ssh/[/url]

Member Avatar for programmersbook
0
197
Member Avatar for cyborg22

how about: [CODE] struct movieData { std::string title; std::string director; int year; int time; };[/CODE]

Member Avatar for programmersbook
0
381
Member Avatar for bobsta

did you try: [CODE] fourMatrix::fourMatrix(fourVector a, fourVector b, fourVector c, fourVector d): i(a),j(b),k(c),l(d){ }[/CODE] else the compiler takes "i" as local variable or use: [CODE]class fourMatrix{ public: fourVector m_i,m_j,m_k,m_l; ... }[/CODE] then you see is a class attribute [CODE] fourMatrix::fourMatrix(fourVector i, fourVector j, fourVector k, fourVector l): m_i(i), m_j(j), m_k(k), …

Member Avatar for MrSpigot
0
97
Member Avatar for kako13

did you try: [CODE] fstream file; file.open("Tbl_cliente.txt", ios::in); // open a file for input file.unsetf(ios::skipws); getline(file, Cli_nombre, '#'); getline(file, Cli_apellido, '#'); getline(file, Cli_dirr, '#'); getline(file, Cli_total_compras, '#'); getline(file, Cli_balance, '#');[/CODE]

Member Avatar for necrolin
0
140
Member Avatar for mcap61

Hi! Sorry the [url]http://www.cs.nccu.edu/~gmilledge/co...ynames2004.txt[/url] doesnt work. I think you should use std::list, and no pointers if it's not neccessary! It will make your wile easier ;)

Member Avatar for programmersbook
0
366
Member Avatar for Spiderpig085
Member Avatar for merse
Member Avatar for Narue
0
135
Member Avatar for lewashby

a little suggestion: [CODE] def set_name(self, new_name): #-----------------------------set's a value to a private name? if not new_name: raise ValueError, "A critter's name can't be the empty string." self.__name = new_name print "Name change successful."[/CODE] [CODE]try: crit.name = "" except ValueError, e: print e[/CODE]

Member Avatar for lrh9
0
262
Member Avatar for grib
Member Avatar for grib
0
145
Member Avatar for Premlal

Hi! I would create a base class, from which the myTemplateClass will inherit. like this: [CODE] class TemplateClassBase{}; template<class C>class myTemplateClass : TemplateClassBase{};[/CODE] This should be a list: [CODE]myTemplateClass * templateClassPtrArray[10];[/CODE] This is better: [CODE]std::list<TemplateClassBase*> templateClassPtrArray;[/CODE] [CODE]templateClassPtrArray.push_back( new myTemplateClass<int>() ); templateClassPtrArray.push_back( new myTemplateClass<char>() ); [/CODE] Code is NOT tested, was …

Member Avatar for Premlal
0
2K
Member Avatar for Happypants

You should type cast it: [CODE]float bmi =(float) (weight/(height*height)); [/CODE]

Member Avatar for Happypants
0
171
Member Avatar for kirennian

did you try: [CODE]typedef struct DISPLAY_DEVICE_CAPABILITIES{ vector<int[3]> resolutions; int brightness; }DISPLAY_DEVICE_CAPABILITIES;[/CODE]

Member Avatar for kirennian
0
210
Member Avatar for bhavz
Member Avatar for karthik.c

did you try: [CODE]int i=0; int ch=recv(new_socket,(void*)&i,sizeof(int),0); printf("Value of a is :%d\n", i);[/CODE]

Member Avatar for programmersbook
0
3K
Member Avatar for yakovm

The keys are unique, if the key is already present he will be updated. Use multimap to insert each time a new value.

Member Avatar for programmersbook
0
129