Friday, May 17, 2013

Program C++ 10 Creat Code Program

Name : Om Chanlyta
Major : TMD
NIM : 49012081

Hello teacher below is my video and code program  to say about Create Code Program about Average Student.

/*Average of Student
  Name : Om Chanlyta
  NIM : 49012081
  ======================*/
#include<iostream>
using namespace std;
  double Total;
  double Db,C,CC,Arc,Net,TotalAverage;
  int FunctionAverage(double TotalAverage)
  {
    cout<<"Please input point of C++ program"<<endl;
    cin>>CC;
    cout<<endl;
    cout<<"Please input point of Database"<<endl;
    cin>>Db;
    cout<<endl;
    cout<<"Please input point of C progarm" <<endl;
    cin>>C;
    cout <<endl;
    cout<<"Please input point of Architicture" <<endl;
    cin>>Arc;
    cout <<endl;
    cout<<"Please input point of Network" <<endl;
    cin>>Net;
    cout <<endl;
    TotalAverage = (CC+Db+C+Arc+Net)/5;
    cout<<"Average point of student are epual"<<TotalAverage<<endl;
    return TotalAverage;
  }

  int main()
  {
      int Amount,i,NIM;
      char Name[20];
      cout<<"Please Input Amount of Student \n";
      cin>>Amount;
      do{
          cout<<"===============================================\n\n";
          for(i=1; i<=Amount; i++){
            cout<<"Name : ";
            cin>>Name;
            cout<<endl;
            cout<<"NIM : ";
            cin>>NIM;
            cout<<endl;
            Total = FunctionAverage(Total);
            if(Total<=100 && Total>=50)
            {
                cout<<"\n You are Pass" <<endl<<endl;
            }
            else if(Total<50 && Total>=0)
            {
                cout<<"\n You are False" <<endl<<endl;
            }
            else{
                cout<<"Poing that you input is wrong" <<endl;
                cout<<"Please input again" <<endl<<endl;
                }
            cout<<"============================================\n\n";

          }

      }while(Total>100);
      system("pause");
      return 0;
  }






Below is my link to this video in youtube :
http://www.youtube.com/watch?v=ktYpbmyiqJE&feature=youtu.be

Program C++ Module 9 Function

Name : Om Chanlyta
Major : TMD
NIM : 49012081

Hello teacher this is my video that say about Program C++ Module 9 Function.



This is my link to this video : http://www.youtube.com/watch?v=dvRljPNe0aY&feature=youtu.be

Program C++ Module 8 Structure

Name : Om Chanlyta
Major : TMD
NIM : 49012081

Hello teacher below is my video to say about Module 8 Structure .



This is my link : http://www.youtube.com/watch?v=gJOQA40AjoI&feature=youtu.be

Program C++ Module 7 Array

Name : Om Chanlyta
Major : TMD
NIM : 49012081
Hello teacher bellow is my video that say about Module 7 Array.





 
Link to my video as below:

Program C++ Module 6 Repeat

Name : Om Chanlyta
Major : TMD
NIM : 49012081

Hello teacher below is my video that say about Program C++ in Module 6 Repeat.



Link to my video as below:
http://www.youtube.com/watch?v=a9F6wrZPYb8&feature=youtu.be

Module 5

Name: Om Chanlyta
Major: TMD



http://www.youtube.com/watch?v=lhFos4czQGY&feature=youtu.be

Module 4

Name: Om Chan Lyta
Major: TMD


http://www.youtube.com/watch?v=UxZuxd3MRhU&feature=youtu.be

Module 3

Name: Om Chan Lyta
Major: TMD


http://www.youtube.com/watch?v=H_ofHQQATX4&feature=youtu.be

Module 2

Name : Om Chan Lyta
Major: TMD



http://www.youtube.com/watch?v=EJCFBkV2uDM&feature=youtu.be

Module 1

Name: Om Chan Lyta
Major: TMD



http://www.youtube.com/watch?v=FA6bMY-RxY4&feature=youtu.be


http://www.youtube.com/watch?v=WT1Fgu0w4rQ&feature=youtu.be

How to create and explain Tower Game

Name : Om Chanlyta
Major : TMD
 Hello professor this video with code is create tower game :

#include <stdio.h>
#include <stdlib.h>
int main (void)
{
    int m;
    void hanoi(int n, char a, char b, char c);
    printf("Enter the number of discs>");
    scanf_s("%d",&m);
    printf("Step-by-step removal of discs: \n");
    hanoi(m,'1','2','3');
    system("pause");
    return 0;
}
void hanoi(int n, char x, char y, char z)
{
    if(n==1)
        printf("Move the top disk from pole % c to pole %c \n",x,z);
    else
    {
        hanoi(n-1,x,z,y);
        hanoi(1,x,y,z);
        hanoi(n-1,y,x,z);
    }
}



This is my link : http://www.youtube.com/watch?v=KfuUHfXSEik&feature=youtu.be

How to Create Work Dates arithmetic program Tomorrow

Name : Om Chanlyta
Major : TMD

Hello processor these code and video below are show you about how to create work date arithmetic program tomorrow :

#include <stdio.h>
#include <stdlib.h>
int main(){
    struct days
    {
        int day;
        int month;
        int year;
    };
    struct days now,tomorrow;
    int tdate[12] = {31,28,31,30,31,30,31,31,30,31,30,31};
    printf("Input value of day ");
    scanf_s("%d",&now.day);
    printf("\nInput value of month ");
    scanf_s("%d",&now.month);
    printf("\nInput value of year ");
    scanf_s("%d",&now.year);
    if(now.day<tdate[now.month-1])
    {
        tomorrow.day=now.day+1;
        tomorrow.month=now.month;
        tomorrow.year=now.year+1;
    }
    else if (now.month ==12)
    {
        tomorrow.day=1;
        tomorrow.month=1;
        tomorrow.year =now.year + 1;

    }
    else
    {
        tomorrow.day =1;
        tomorrow.month = now.month + 1;
        tomorrow.year = now.year;
    }
    printf("\n tomorrow is day %d month %d year %d \n", tomorrow.day,tomorrow.month,tomorrow.year);
    system("pause");
}





This is my link :
http://www.youtube.com/watch?v=A-dOJmmsT9E&feature=youtu.be

How to create a program to copy the contents of the array A to array B are empty by the number

Name : Om Chanlyta
Major : TMD

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

int main(){
    int label =5, k = 0;
    int A[5];
    int B[5];
    for(k=0; k<label;k++){
        printf("Please input value %d :\n",k+1);
        scanf("%d", &A[k]);

    }
    printf("Array : int A[5]; \n");
    printf("Index : 1 2 3 4 5 \n");
    printf("Value :");
    for(k = 0; k<label; k++){
        printf("%d",A[k]);
        B[k] = A[k];
    }

    printf("\n\n Array : int B[5]; \n");
    printf("Index : 1 2 3 4 5 \n");
    printf("Value :");
    for (k = 0; k < label; k++){
        printf("%d", B[k]);
    }
    printf("\n");
    system("pause");
}

Below is my video :

This is my link:
http://www.youtube.com/watch?v=1U5YZMMIOyA&feature=youtu.be

How to Create Code Program Exchange Rp to Dolla

Name: Om Chanlyta
Major: TMD


#include<stdio.h>
#include<stdlib.h>
#include<math.h>
int main(void)
{
void exchang(int h,int c);
int t, e;
printf("\n Insert Your Money Amount \n");
scanf("%d", &e);
printf("\n Insert rate \n");
scanf("%d", &t);
exchang(t,e);
system("pause");
return(0);
}
void exchang(int h,int c)
{
int t= float(c/h);
int e = c % h;
printf("Your Money Amount = %d \n",c);
printf("Rate = %d \n", h);
printf("You Get Money = %d USA$\n",t);
printf("Your Letf Money = %d \n",e);
}

Below is my video :



This is my link:

http://www.youtube.com/watch?v=OZUrFU-tMgc&feature=youtu.be

How to Write a program that contains a calculation of the volume of a triangular pyramid and volume of a sphere

Hello lecture
My Name: Om Chanlyta
Major: TMD


#include<stdio.h>
#include<stdlib.h>
int main (void)
{

int a;

float b,h1,h2,v,pi=3.14159,r;
do{
printf("Please input value = ");
scanf_s("%d",&a);

switch(a)
{
case 1:
printf("Calculator volume of triangular pyramid\n");
printf("Please input value of base=");
scanf_s("%f",&b);
printf("Please input value of base height= ");
scanf_s("%f",&h1);
printf("please input value of pyramid height=");
scanf_s("%f",&h2);
v=(((b*h1)/2)*h2)/3;
printf("volume of traingular pyramid is=%f\n",v);
break;
case 2:
printf("Calculator volume of sphere\n");
printf("Please input value of radius=\n");
scanf_s("%f",&r);
v=((pi*r*r*r)*4)/3;
printf("volume of sphere is= %f\n",v);
break;
default:
printf("you do not type number 1 or 2 ");
break;
}

}while ((a!=1)&&(a!=2));

system ("pause");
return(0);

}

Below is video of How to Write a program that contains a calculation of the volume of a triangular pyramid and volume of a sphere:

This is my link :

Tugas II : How to use operator in program c

Name : Om Chanlyta
Major : TMD

Hello, professor the video will show about define the calculation operations and explanation in the form of
comments in the code.




below is my link :
http://www.youtube.com/watch?v=Aj0nN-78HmM&feature=youtu.be