--- In cprogramming2@yahoogroups.com, sempaiga <no_reply@...> wrote:
>
> I need to open a text file that my compression application
> I am coding should read. when I create a text file in the
> compiler itself ( its name was given by the compiler itself
> as (TextFile1.txt)) and fill it with text to be read by the
> program I have written , the application comes back with the
> message."sourcefile is empty of any data" or "cannot open the
> source file".
<snip>
Please post the smallest piece of code which shows this behaviour, only then can
we try to help you. Without seeing your code there's no use in guessing what may
be wrong.
Regards,
Nico
alaaziz64 wrote:
>
>
> hi all
> i work on project
> one part is to write a c program that read my yahoo email
> can any 1 help me in this
>
google for pop3 email C/C++ libraries and how to use them
if you can access your yahoo email via imap, you can also google for imap C/C++
libraries and how to use them
It depends on what kind of yahoo email you have. Let's say you have a local yahoo email, such as: yahoo.co.id, yahoo.co.uk, and so on... you can access it easily using any available SMPT or POP3 library for c++. But if your id is yahoo.com, you can not acces it using SMTP or POP3 protocol. You need to refer to fetchyahoo or ypop project for this.
If you want to know seriously, first, read RFC about how POP3 ans SMTP protocol works. Also equip yourself with network programming such as how to hande socket.
Here some good
references: http://www.codeproject.com/KB/IP/CSmtp.aspx http://www.codeproject.com/KB/IP/cpop3conn.aspx http://www.codeproject.com/KB/IP/win32_pop3.aspx
Good luck!
Auralius
--- Pada Jum, 30/10/09, Reid Thompson <jreidthompson@...> menulis:
alaaziz64 wrote:
>
>
> hi all
> i work on project
> one part is to write a c program that read my yahoo email
> can any 1 help me in this
>
google for pop3 email C/C++ libraries and how to use them
if you can access your yahoo email via imap, you can also google for imap C/C++ libraries and how to use them
Please refer the book, ANSCI C by Balagurusamy. This program is in last page..
From: basharatazad a <basharatazad@...> Subject: [C Programming] Write a program in c++ To: cprogramming2@yahoogroups.com Date: Wednesday, 21 October, 2009, 1:18 PM
Write a C++ program to implement employee directory, which will let the organization to perform the following functions:
1) Insert the record of new employee 2) Delete the record of an existing employee 3) Find the record of an existing employee 4) Display Report
Following information of each employee will be stored
Employee ID: an integer value to store the unique id for each employee Employee Name: the name of each employee. Employee Address: Address of each employee Employee Salary: a float value to store salary of each employee.
Hi Everyone,
I am trying to break down the byte into small pieces of bits. Here is what I
want to do. open for any suggestions.
typedef struct
{
unsigned char a : 2;
unsigned char b : 3;
unsigned char c : 3;
} test_byte;
int main()
{
unsigned char n1 = 8;
test_byte tb1;
tb1 = *(test_byte *)n1;
}
output:
tb1.a = bit0 bit1
tb1.b = bit2 bit3 bit4
tb1.c = bit5 bit6 bit7
this is what I am trying to do any suggestions please welcome.
Thanks....
On Thu, Nov 5, 2009 at 2:43 PM, kumraki <kumraki@...> wrote:
>
> Hi Everyone,
>
> I am trying to break down the byte into small pieces of bits. Here is what I
want to do. open for any suggestions.
Don't use structs - it's overkill. And potentially relying on
behaviour that may not be portable.
> typedef struct
> {
> unsigned char a : 2;
> unsigned char b : 3;
> unsigned char c : 3;
> } test_byte;
int bits01(unsigned char c){
return (c & 0x03);
}
int bits234(unsigned char c){
return (c >> 2) & 0x07;
}
int bits 567(unsigned char c){
return (c >> 5) & 0x07;
}
I suggest you change the names of the functions to more accurately
represent what those bit groupings actually represent.
> int main()
> {
> unsigned char n1 = 8;
> test_byte tb1;
>
> tb1 = *(test_byte *)n1;
>
> }
> output:
> tb1.a = bit0 bit1
> tb1.b = bit2 bit3 bit4
> tb1.c = bit5 bit6 bit7
>
> this is what I am trying to do any suggestions please welcome.
>
> Thanks....
--
PJH
http://shabbleland.myminicity.com/http://www.chavgangs.com/register.php?referer=9375http://www.kongregate.com/?referrer=Shabble
I know this code has more to do with assembly than C but that's why
I am having trouble understanding it. I am not sure why the code
pushes SI twice and why push DI when it's not used. I need to know how does C
function know how to return the average so that assembly can retrieve it.
I think i need to fully understand this before i work on a program of my own
with mixed mode.
/* An example to illustrate C function -> assembly -> a C function.
This program calls the assembly language procedure in file MARKS_A.ASM.
The program outputs min, max, and rounded average of two marks. */
#include <stdio.h>
int main(void)
{ int mark1,mark2, min, max, av;
int find_avg(int, int);
extern void stats(int, int, int*, int*, int*);
scanf("%d%d",&mark1,&mark2);
stats(mark1,mark2, &min, &max, &av);
printf("Min = %d, Max = %d, Av = %d\n", min, max, av);
return 0; }
/*********************************************************
* Returns the rounded average required by the assembly
* procedure STATS in file MARKS_A.ASM.*/
int find_avg(int total, int number) {
return((int)((double)total/number + 0.5)); }
;---------------------------------------------------------
; Assembly program example to show call to a C function.
; This procedure receives a marks array and class size
; and returns minimum, maximum, and rounded average marks.
;---------------------------------------------------------
.MODEL SMALL
EXTRN _find_avg:PROC
.CODE
PUBLIC _stats
_stats PROC
push BP
mov BP,SP
push SI
push DI
mov AX,[BP+4] ; AX := mark1
mov DX,[BP+6] ; DX := mark2
cmp AX,DX ; put min into AX and max into DX
jl next
xchg AX,DX
next:
: mov SI,AX ; SI gets sum
add SI,DX
mov BX,[BP+8] ; return minimum
mov [BX],AX
mov BX,[BP+10] ; return maximum
mov [BX],DX
; now call find_avg C function to compute average
mov AX,2 ;push number of marks
push AX
push SI ;push sum of marks
call _find_avg ; returns average in AX
add SP,4 ; clear stack
mov BX,[BP+12] ; return average
mov [BX],AX
pop DI
pop SI
pop BP
ret ; NOTE calling program clears stack
_stats ENDP
END
Saving and restoring BP,SI,DI is probably a formality included whether they
happen to be used or not (at least by the author of this program). Those are the
only registers required to be preserved.
The second push for SI that appears in:
push AX
push SI ;push sum of marks
call _find_avg ; returns average in AX
add SP,4 ; clear stack
is only to set up the two parameters (total,number) in that order on the stack
for the _find_avg subroutine. SI is the total.
--- In cprogramming2@yahoogroups.com, "snowflakecardigan"
<snowflakecardigan@...> wrote:
>
> I know this code has more to do with assembly than C but that's why
> I am having trouble understanding it. I am not sure why the code
> pushes SI twice and why push DI when it's not used. I need to know how does C
function know how to return the average so that assembly can retrieve it.
>
> I think i need to fully understand this before i work on a program of my own
with mixed mode.
>
>
> /* An example to illustrate C function -> assembly -> a C function.
> This program calls the assembly language procedure in file MARKS_A.ASM.
> The program outputs min, max, and rounded average of two marks. */
>
> #include <stdio.h>
> int main(void)
> { int mark1,mark2, min, max, av;
> int find_avg(int, int);
> extern void stats(int, int, int*, int*, int*);
> scanf("%d%d",&mark1,&mark2);
> stats(mark1,mark2, &min, &max, &av);
> printf("Min = %d, Max = %d, Av = %d\n", min, max, av);
> return 0; }
>
>
> /*********************************************************
> * Returns the rounded average required by the assembly
> * procedure STATS in file MARKS_A.ASM.*/
>
> int find_avg(int total, int number) {
> return((int)((double)total/number + 0.5)); }
>
>
> ;---------------------------------------------------------
> ; Assembly program example to show call to a C function.
> ; This procedure receives a marks array and class size
> ; and returns minimum, maximum, and rounded average marks.
> ;---------------------------------------------------------
> .MODEL SMALL
> EXTRN _find_avg:PROC
> .CODE
> PUBLIC _stats
> _stats PROC
> push BP
> mov BP,SP
> push SI
> push DI
>
>
> mov AX,[BP+4] ; AX := mark1
> mov DX,[BP+6] ; DX := mark2
> cmp AX,DX ; put min into AX and max into DX
> jl next
> xchg AX,DX
> next:
> : mov SI,AX ; SI gets sum
> add SI,DX
>
> mov BX,[BP+8] ; return minimum
> mov [BX],AX
> mov BX,[BP+10] ; return maximum
> mov [BX],DX
>
> ; now call find_avg C function to compute average
>
> mov AX,2 ;push number of marks
> push AX
> push SI ;push sum of marks
> call _find_avg ; returns average in AX
> add SP,4 ; clear stack
> mov BX,[BP+12] ; return average
> mov [BX],AX
> pop DI
> pop SI
> pop BP
> ret ; NOTE calling program clears stack
> _stats ENDP
> END
>
Hi Folks,
I need some help in XOR the bits in a byte 8 bits.
flag bit = b1 xor b2 xor b3 xor b4 xor b5 xor b6 xor b7 xor b8
I want to do this with minimal operations in C.
thanks.
Hello Group!
I was wondering what the breakdown of the group members is regarding using c
versus c++?
Just a ballpark figure. c/c++. 50/50? 90/10? 10/90? 1/99?
99/1?
I am learning c++. strictly recreational. I am most familiar with BASIC, but
figured it's time to learn something used in this century. I am using "C++
Primer Plus" (Stephen Prata) as a text.
I also am a devoted Mac person, but am starting to think that c++ is not a good
choice for the Mac.
Rob Keister
____________________________________
Can vegetarians eat animal crackers?
On Sun, Nov 8, 2009 at 8:04 PM, rskeister <rkeister@...> wrote:
> Hello Group!
>
> I was wondering what the breakdown of the group members is regarding using c
versus c++?
> Just a ballpark figure. c/c++. 50/50? 90/10? 10/90? 1/99?
99/1?
You appear to be missing the group that uses both.
> I also am a devoted Mac person, but am starting to think that c++ is not a
good choice for the Mac.
I'm sure modern versions of FruitOS come with gcc.
--
PJH
http://shabbleland.myminicity.com/http://www.chavgangs.com/register.php?referer=9375http://www.kongregate.com/?referrer=Shabble
On Sun, 2009-11-08 at 20:04 +0000, rskeister wrote:
>
> Hello Group!
>
> I was wondering what the breakdown of the group members is regarding
> using c versus c++?
> Just a ballpark figure. c/c++. 50/50? 90/10? 10/90? 1/99? 99/1?
>
> I am learning c++. strictly recreational. I am most familiar with
> BASIC, but figured it's time to learn something used in this century.
> I am using "C++ Primer Plus" (Stephen Prata) as a text.
>
> I also am a devoted Mac person, but am starting to think that c++ is
> not a good choice for the Mac.
>
I do a lot of C, I do no C++.
Mac -> native is mostly Objective-C I think.
I imagine that if Apple's compiler doesn't handle C, that gcc would be
available for OSX.
http://developer.apple.com/mac/library/documentation/cocoa/Conceptual/ObjectiveC\
/Introduction/introObjectiveC.html
The Objective-C language is a simple computer language designed to
enable sophisticated object-oriented programming. Objective-C is defined
as a small but powerful set of extensions to the standard ANSI C
language. Its additions to C are mostly based on Smalltalk, one of the
first object-oriented programming languages. Objective-C is designed to
give C full object-oriented programming capabilities, and to do so in a
simple and straightforward way.
--- On Tue, 10/11/09, kumraki <kumraki@...> wrote:
From: kumraki <kumraki@...> Subject: [C Programming] XOR the bits in a word To: cprogramming2@yahoogroups.com Date: Tuesday, 10 November, 2009, 1:01 PM
Hi Folks,
I need some help in XOR the bits in a byte 8 bits.
flag bit = b1 xor b2 xor b3 xor b4 xor b5 xor b6 xor b7 xor b8
I want to do this with minimal operations in C.
thanks.
Add whatever you love to the Yahoo! India homepage. Try now!
I have a programming project that i need help with. I have to do the C program
then dram the flowchart. I have already done the program but i have problem
doing the flowchart can someone help me
On some groups you can create a poll but I don't see how to do it here. Right
now I use C for embedded and C++ and C# (these 2 for consumer apps) and VB for
my own utilities.
BasicPoke
--- In cprogramming2@yahoogroups.com, "rskeister" <rkeister@...> wrote:
>
> Hello Group!
>
> I was wondering what the breakdown of the group members is regarding using c
versus c++?
> Just a ballpark figure. c/c++. 50/50? 90/10? 10/90? 1/99?
99/1?
>
> I am learning c++. strictly recreational. I am most familiar with BASIC, but
figured it's time to learn something used in this century. I am using "C++
Primer Plus" (Stephen Prata) as a text.
>
> I also am a devoted Mac person, but am starting to think that c++ is not a
good choice for the Mac.
>
> Rob Keister
> ____________________________________
> Can vegetarians eat animal crackers?
>
On Sun, Nov 8, 2009 at 8:04 PM, rskeister <rkeister@zippnet.net> wrote: > Hello Group! > > I was wondering what the breakdown of the group members is regarding using c versus c++? > Just a ballpark figure. c/c++. 50/50? 90/10? 10/90? 1/99? 99/1?
You appear to be missing the group that uses both.
> I also am a devoted Mac person, but am starting to think that c++ is not a good choice for the Mac.
I'm sure modern versions of FruitOS come with gcc.
On Sun, 2009-11-15 at 16:38 -0800, Rob Keister wrote:
>
> Well there you go. As a newbie it didn't occur to me that of course
> there would multi-lingual programmers.
> On Nov 12, 2009, at 6:18 AM, cprogramming2@yahoogroups.com wrote:
>
> > On Sun, Nov 8, 2009 at 8:04 PM, rskeister <rkeister@...>
> > wrote:
> > > Hello Group!
> > >
> > > I was wondering what the breakdown of the group members is
> > regarding using c versus c++?
> > > Just a ballpark figure. c/c++. 50/50? 90/10?
> > 10/90? 1/99? 99/1?
> >
> > You appear to be missing the group that uses both.
> >
> > > I also am a devoted Mac person, but am starting to think that c++
> > is not a good choice for the Mac.
> >
> > I'm sure modern versions of FruitOS come with gcc.
>
>
Actually, the example you provided does show both.
c/c++ -> 50/50 -> uses c 50% of the time and c++ 50% of the time
c/c++ -> 90/10 -> 90% 10%
c/c++ -> 10/90 -> 10% 90%
reid
void printdata() { cout << "The title is: " << title << endl; }
};
class sales {
protected:
float *no_of_three_months_sales[3];
public: void getdata() { cout << "Enter the sales of three months: "; for(int i=0; i < 3; i++) cin >> no_of_three_months_sales[i]; }
void printdata() { for(int i=0; i < 3; i++) cout << "The sales for " << i + 1 << "month is " << no_of_three_months_sales[i] << endl; }
};
class book:public publisher, sales { float price; int pages;
public: void getdata() {
publisher::getdata(); cout << "Enter the price of book: "; cin >> price; cout << "Enter the no. of pages: "; cin >> pages; sales::getdata(); }
void printdata() { publisher::printdata(); cout << "The price of the book is: " << price << endl; cout << "The no. of pages is: " << pages << endl; sales::printdata(); } };
class tape:public publisher, sales { float
time; float price;
public: void getdata() { publisher::getdata(); cout << "Enter the playing time: "; cin >> time; cout << "Enter the price of the tape: "; cin >> price; sales::getdata(); }
void printdata() { publisher::printdata(); cout << "The playing is: " << time << endl; cout << "The price of the tape is: " << price << endl;
sales::printdata(); }
};
int main() { book b; tape t; b.getdata(); t.getdata(); b.printdata(); t.printdata();
Hi,
I am not able to understand the output of the following:
unsigned char x;
x = 300;
printf("%d",x);
int x,y;
x = 5;
y = 10;
printf("%d\t%d\t%d\t%d\t",x++,y++,++x,++y);
I am not able to understand the output of following C program :
unsigned char x; x = 300; printf("%d",x);
int x,y; x = 5; y = 10; printf("%d\t%d\t%d\t%d\t",x++,y++,++x,++y);
Following is the C++ Program giving error:
#include<iostream> using namespace std;
class furniture { protected: char *color; int width, height; };
class shelf:public furniture { int no_of_shelves; public: shelf(char *c, int w, int h, int s) { color = c; width =
w; height = h; no_of_shelves = s; }
void print() { cout << "Colour is: " << color << endl; cout << "Width is: " << width << endl; cout << "Heigth is: " << height << endl; cout << "No of Shelves is: " << no_of_shelves << endl; }
};
int main() { char *col; int width, height, no_of_shelf; cout << "Enter the colour of Shelf: "; cin >> col; cout << "Enter the
width of shelf: "; cin >> width; cout << "Enter the heigth of shelf: "; cin >> height; cout << "Enter the number of shelf: "; cin >> no_of_shelf;
Is there any proof this is real? I'm a student and would be great but I've never
actually seen a work at home program thats real.
--- In cprogramming2@yahoogroups.com, anil_jupiter <no_reply@...> wrote:
>
> Work from Home opportunity...........Only for serious people .....
>
> Ideal for Homemakers, students or people with spare time in day .....
>
> Please complete this form
>
>
http://spreadsheets.google.com/viewform?formkey=dE5ET3l5eW5rS3RsQUdNUzF1ZGVST1E6\
MA
>
Sad to say these are generally just spams. I tend to be wary of any who ignore
the lists topics lie that. You're more likely to end up with even more spam
by replying to it and prob more virii sent your way. You'll note there's no
mention of the company looking to hire. That's so you can't check up on it
James
On Monday 23 November 2009 08:44:34 the_black_angel13 wrote:
> Is there any proof this is real? I'm a student and would be great but I've
> never actually seen a work at home program thats real.
>
> --- In cprogramming2@yahoogroups.com, anil_jupiter <no_reply@...> wrote:
> > Work from Home opportunity...........Only for serious people .....
> >
> > Ideal for Homemakers, students or people with spare time in day .....
> >
> > Please complete this form
> >
> > http://spreadsheets.google.com/viewform?formkey=dE5ET3l5eW5rS3RsQUdNUzF1Z
> >GVST1E6MA
Sorry that I haven't seen this stupid spam message early enough.
I have removed this person from the forum and will continue to do so in the
future.
These spam posts are the reason why I've set every new member of this board to
Moderated status. Sad to see that sometimes I miss one or the other. Sorry for
that.
Regards,
Nico
They usually have categories specifically for positions specifically in the computer field
Good Luck! Kiandra
Kiandra Plummer Internet Research & Marketing Professional Email: kpsourcerqueen@... Let's Stay Connected http://www.linkedin.com/in/kiandra
From: Paul Herring <pauljherring@...> To: cprogramming2@yahoogroups.com Sent: Sun, November 22, 2009 7:02:42 PM Subject: Re: [C Programming] Re: Work from Home opportunity
On Sun, Nov 22, 2009 at 10:44 PM, the_black_angel13
<the_black_angel13@ yahoo.com> wrote:
>
> Is there any proof this is real? I'm a student and would be great but I've never actually seen a work at home program thats real.
I have the following assignment in my one class for the week and a major part of
my grade for the term. I have to interview someone that works within the
Programming field. I was wondering if I could interview a professional
programmer from within this group. I will except interviews with several people
and choose the best one.
The project is due next Tuesday. Any assistance will be highly appreciated.
Thank You
James A Gauntner
Interview questions:
1. What is your title?
2. What are your responsibilities?
3. What kinds of skills do you need to perform your job?
4. Describe what you do during a typical day.
5. What other jobs have you held that might have helped prepare you for this
position?
6. Do you have people who work for you, and what do they do?
7. What is one of the most challenging things about the work you do?
8. What time management tips could you suggest?
9. How do you balance your family, job, work, and leisure time?
10. What advice would you give to someone interested in this career?
Additional information shared, or other interviewer notes (not required):