Ceriwis  

Go Back   Ceriwis > HOBI > Komputer & Teknologi > Programming

Programming Share, tanya jawab, saling bantu antar programmer dengan berbagai macam bahasa pemrograman.

Reply
 
Thread Tools
  #1  
Old 20th November 2011
Linuxmania Linuxmania is offline
Ceriwiser
 
Join Date: Nov 2011
Posts: 392
Rep Power: 14
Linuxmania mempunyai hidup yang Normal
Default MASTRE JAVA SAYA SALAH DIMANA NEh

import java.io.*;

public class hitungdagangan

{

public static void main (String args[]) throws IOException

{

InputStreamReader keyreader;

BufferedReader input;

keyreader=new InputStreamReader (System.in);

input=new BufferReader (keyreader);

int a,n1;

String n;

String kd[],jb[],uk[];

int jb1[],hg[];



double disc[],pjk[],tot[],jhg[];

System.out.println("TOKO.JUALAN MURAH\n");

System.out.println("Masukkan banyak data : ");

n=input.readline();

n1=Integer.parseInt(n);



kd=new String [n1];

jb=new String [n1];

jb1=new int [n1];

hg=new int [n1];

uk=new String [n1];

disc=new double [n1];

pjk=new double [n1];

tot=new double [n1];

jhg=new double [n1];



for(a=0;a10)

disc[a]=0.2*(jhg[a]);

else

disc[a]=0;

pjk[a]=0.1*(jhg[a]);

tot[a]=(jhg[a])-disc[a]-pjk[a];

}



for (a=0;a

Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


 


All times are GMT +7. The time now is 02:43 PM.


no new posts