|
|
Hello, Guest! Welcome to Symbianize forums.
Most of our features and services are available only to our members. So we encourage you to login or join us by registering a new account. Registration is free, fast, and simple. You only need to provide a valid email address so we can minimize spammers. As a Symbianize member you'll have the following privileges:
- Gain access to private forums and restricted features
- Reply and create new topics or polls
- Download free applications, games, themes, graphics, tones, videos, etc.
- Ask question or support related to mobile phone, computer, game console, and multimedia
- Private messaging (PM) with fellow members
- Communicate instantly or real-time with currently online members via Shout Box
All that and more, so what are you waiting for, join us now! Ito ang website na ginawa ng pinoy para sa pinoy!
| |
| Programming Discussions related to C++, HTML, PHP, ASP, ColdFusion, JavaScript, Perl, Phyton, Ruby, WML, SQL, XML, and other programming languages. |
|
View Poll Results: INSTANT FEEDBACK HERE
|
|
LIKE
|
  
|
53 |
96.36% |
|
DISLIKE
|
  
|
2 |
3.64% |
 |
|

14th Jun 2012 Thu, 17:20
|
 |
Forum Advisor
|
|
Join Date: May 2012
Location: Cav-C
Posts: 718
Reputation:
|
|
Re: Share Your C++ Codes Here (Sharing Is Caring)
ask ko lang po mga programmers, ang java po ba parang c++ din?? .. 2nd year college student po ako eh,java daw kasi gamitin namin ngayon
|

15th Jun 2012 Fri, 19:01
|
 |
Forum Advisor
|
|
Join Date: Jul 2010
Location: You ask me..
Posts: 632
Reputation:
|
|
Re: Share Your C++ Codes Here (Sharing Is Caring)
Quote:
Originally Posted by Ako Si Papa Dan
ask ko lang po mga programmers, ang java po ba parang c++ din?? .. 2nd year college student po ako eh,java daw kasi gamitin namin ngayon 
|
halos pareho lang bro.. syntax lang ang pinagkaiba nila,,and mas madali at mas short ang pagcode kasi maraming built-in na functions sa java.. na kung sa C++ ay ima manual mo pa..
Last edited by snowfall07; 15th Jun 2012 Fri at 19:02..
|

19th Jun 2012 Tue, 17:49
|
 |
Forum Master
|
|
Join Date: Jun 2009
Location: Symbianize
Posts: 2,156
Reputation:
|
|
Re: Share Your C++ Codes Here (Sharing Is Caring)
ma mark ts....big thanks
|

19th Jun 2012 Tue, 19:19
|
 |
Expert
|
|
Join Date: Dec 2011
Posts: 268
Reputation:
|
|
Re: Share Your C++ Codes Here (Sharing Is Caring)
#include<iostream.h>
int main()
{
int x, y;
int totalg[3];
int num[3][3];
int total = 0;
int totalx =0;
for(x=0;x<3;x++)
{
total=0;
for(int y=0;y<3;y++)
{
cout<<"enter number "<<y+1<<" for group "<<x+1<<" is : ";
cin>>num[x][y];
total=total+num[x][y];
}
totalg[x]= total;
cout<<endl;
}
for (x=0;x<3;x++)
{
for( int y=0; y<3; y++)
{
cout<<"your number "<<y+1<<" for group "<<x+1<<" is: ";
cout<<num[x][y];
cout<<endl;
}
cout<<endl;
}
for(x=0;x<3;x++)
{
cout<<"total for group "<<x+1<<" is: "<<totalg[x];
cout<<endl;
totalx=totalx+totalg[x];
}
cout<<"total is: "<<totalx<<endl;
return 0;
}
|

19th Jun 2012 Tue, 19:33
|
 |
The Grand Master
|
|
Join Date: Sep 2010
Location: City of the Outcast
Posts: 3,135
Reputation:
|
|
Re: Share Your C++ Codes Here (Sharing Is Caring)
Quote:
Originally Posted by snowfall07
halos pareho lang bro.. syntax lang ang pinagkaiba nila,,and mas madali at mas short ang pagcode kasi maraming built-in na functions sa java.. na kung sa C++ ay ima manual mo pa..
|
parang baliktad ?
hindi ba mas maiksi sa c++.
|

19th Jun 2012 Tue, 19:42
|
 |
Veteran
|
|
Join Date: Nov 2011
Location: ENCRYPTED DETAILS
Posts: 418
Reputation:
|
|
Re: Share Your C++ Codes Here (Sharing Is Caring)
Quote:
Originally Posted by i_ignore08
parang baliktad ?
hindi ba mas maiksi sa c++.
|
lol. are you making me fool? compare the DBC or GUI Design for C++. haha. Please think what you are saying. It will confuse people.
ENLZNEP-ENCRYPTED IDENTITY 
Find me HERE
|

20th Jun 2012 Wed, 18:48
|
 |
Forum Advisor
|
|
Join Date: Sep 2011
Location: Philippines
Posts: 700
Reputation:
|
|
Re: Share Your C++ Codes Here (Sharing Is Caring)
cnung may alam dito sa fstream that can store, edit , search and delete files on the .txt files?
|

22nd Jun 2012 Fri, 04:11
|
 |
Expert
|
|
Join Date: Jun 2011
Location: sa PUSO mo!!
Posts: 278
Reputation:
|
|
Re: Share Your C++ Codes Here (Sharing Is Caring)
pang dagdag decoration i used, po!..
Quote:
#include<iostream.h>
#include<conio.h>
#include<dos.h>
main(){
char ans;
clrscr();
int i, x,y;
x=10,y=4;
for (i=0;i<=40;i++){
gotoxy(x,y); cout<< "*" ;
x++;
delay(10);
}
x=50,y=4;
for (i=0;i<=20;i++){
gotoxy(x,y); cout<< "*" ;
y++;
delay(50);
}
x=50,y=24;
for (i=0;i<=40;i++){
gotoxy(x,y); cout<< "*" ;
x--;
delay(50);
}
x=10,y=24;
for (i=0;i<=20;i++){
gotoxy(x,y); cout<< "*" ;
y--;
delay(50);
}
x=11,y=22;
for (i=0;i<10;i++){
gotoxy(x,y); cout<<"Goodbye";
y--;
delay(50);
}
getch();
}
|
|

28th Jun 2012 Thu, 03:04
|
|
Forum Advisor
|
|
Join Date: Nov 2011
Posts: 508
Reputation:
|
|
Re: Share Your C++ Codes Here (Sharing Is Caring)
Quote:
Originally Posted by jimsrics
cnung may alam dito sa fstream that can store, edit , search and delete files on the .txt files?
|
http://www.symbianize.com/showpost.p...4&postcount=48
|

11th Jul 2012 Wed, 01:45
|
 |
Trainee
|
|
Join Date: Aug 2011
Posts: 20
Reputation:
|
|
Re: Share Your C++ Codes Here (Sharing Is Caring)
Quote:
Originally Posted by rodeltotz
help naman po sir?
nid ko po ng code ng ascending and descending sa c++
first step is mg input ka muna ng 10 no.s den enter lalabas ung ascending na 10 no.s ksma na din ung another 10no.s na nkadescending.
bale po 3 columns po un.
unang column ay para sa pg input ng 10 numbers.
tas anoder column sa ascending gnun din sa descending..
pls help po..
|
#include<iostream>
using namespace std;
const int size=10;
void bubbleSort(int[size],int);
void swap(int[size],int,int);
void display(int[size]);
int main(void)
{
int a[size]={69,96,89,360,720,3,0,5,33,100};
display(a);
bubbleSort(a,0);
display(a);
bubbleSort(a,1);
display(a);
system("pause");
return 0;
}
void display(int x[size])
{
for(int i=0;i<size;i++)
cout<<x[i]<<" ";
cout<<endl;
}
void swap(int x[size],int b,int c)
{
int temp;
temp=x[b];
x[b]=x[c];
x[c]=temp;
}
void bubbleSort(int x[size],int s)
{
bool noSwap=false;
while(noSwap==false)
if(s==0)
{
noSwap=true;
for(int i=0;i<size-1;i++)
{
if(x[i]>x[i+1])
{
swap(x,i,i++);
noSwap=false;
}
}
}
else if (s==1)
{
noSwap=true;
for(int i=0;i<size-1;i++)
{
if(x[i]<x[i+1])
{
swap(x,i,i++);
noSwap=false;
}
}
}
}
ikaw na bahala mg edit jan. sana maka tulong.
Last edited by ajbm6; 11th Jul 2012 Wed at 01:52..
Reason: update
|
 |
|
All times are GMT +8. The time now is 05:06.
|