Can someone please check my syntax? Thanks.
The program runs but the output has some kind of error.
Thanks.

#include<stdio.h>
#include<conio.h>
#include<string.h>

void Pig_Latin_Converter()
{ char str[50];
char nv[50]="yay";
char c[50]="ay";
char key[]="aeiou";
char keys[]="bcdfghjklmnpqrstvwxyz";
char test[20];
char *p=str;
scanf("%s",str);

{ p=strpbrk(str,key);
if(str!=p)
{ strcat(str,nv);
printf("Output: %s", str); } }
{ p=strpbrk(str,key);
if(str==p)
{ strcat(str,nv );
printf("Output: %s",str); } }

{ p=strpbrk(str,keys);
if(str==p)
{ char *p=str;
p++;
test[0] = str[0];
strcat(p,test);
strcat(p,c);

printf("\nOutput: %s",p);} }
}

void main()
{ clrscr();
Pig_Latin_Converter();
getch();
}

We're not here to fix all of your problems. Learn to debug your own code. If you have a specific problem, ask a specific question.

Can someone please check my syntax? Thanks.
The program runs but the output has some kind of error.
Thanks.

#include<stdio.h>
#include<conio.h>
#include<string.h>

void Pig_Latin_Converter()
{ char str[50];
char nv[50]="yay";
char c[50]="ay";
char key[]="aeiou";
char keys[]="bcdfghjklmnpqrstvwxyz";
char test[20];
char *p=str;
scanf("%s",str);

{ p=strpbrk(str,key);
if(str!=p)
{ strcat(str,nv);
printf("Output: %s", str); } }
{ p=strpbrk(str,key);
if(str==p)
{ strcat(str,nv );
printf("Output: %s",str); } }

{ p=strpbrk(str,keys);
if(str==p)
{ char *p=str;
p++;
test[0] = str[0];
strcat(p,test);
strcat(p,c);

printf("\nOutput: %s",p);} }
}

void main()
{ clrscr();
Pig_Latin_Converter();
getch();
}

can you please give me the algorithm to convert English into Latin .I want an example like if there is a word "test" than what would be it in Latin.

can you please give me the algorithm to convert English into Latin .I want an example like if there is a word "test" than what would be it in Latin.

1) Buy a Latin-English Dictionary.
2) Look up English word in the dictionary.
3) Read the Latin translation given.
4) Use the Latin word 10 times that day and the word will be yours to use.

1) Buy a Latin-English Dictionary.
2) Look up English word in the dictionary.
3) Read the Latin translation given.
4) Use the Latin word 10 times that day and the word will be yours to use.

thanks alot.:yawn:

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.