找回密码
 加入华同
搜索
黄金广告位联系EMAIL:[email protected] 黄金广告[email protected]
查看: 1239|回复: 2

高手啊,有没有人可以教我做JAVA程序啊

[复制链接]
发表于 2006-5-24 02:10:29 | 显示全部楼层 |阅读模式
汗,真是不知道怎么写,同学找了个哥哥,3个小时就搞定了,我编了3天,还有100多个错,可怕啊. n, k$ X; e3 s" V7 u8 T5 Z
有没有高手帮我哦,周5就要交了,我的邮箱是[email protected],谢谢啦
' M7 Z6 O, Q0 p# u9 ?2 KRequirements:  ! e3 Y- t- z( y0 O
Consider the three Java Classes: Borrow, RepayCalc and RepayCalcMenu, available from the  5 D( h( d0 g% U$ q$ U
Assignment 2 page on Vista.  ) `3 W$ a2 d9 k1 [- m
  4 E1 C5 Z+ e6 e' G
You are required to perform the following tasks:  $ V8 W8 O9 X6 ]3 }5 U+ e  s
  
1 f% e6 i& ]: f& }0 RThe RepayCalcMenu class: (Total maximum 20 marks available)  6 R! G' G; u, N1 l1 ^

/ f0 T9 A4 U! I; c/ ~& O      1.   Provide a basic text-based interface to a Repayment Calculator for the Megalodon  
0 n# ]" H9 e/ E. G8 p" ?           Finance Company so that it can be used by the Megalodon staff members to  
+ a& T, W" A8 ^1 d/ l, q           determine repayment options for their clients.  / R- k# K) k* l/ i" `" `
2 u& D$ Q8 i6 {6 {) d
           The staff must be able to:  
4 l3 D9 i" v+ {% G2 d- X" u* K
+ Q) p$ a  d1 D# B. {           *    Log on to the ‘system’ using their user name and a Personal Identification  
$ Q* U2 E9 |6 q1 {5 Z5 `                Number (PIN), which a four digit number **.   
- t. _2 }8 F* k! f2 H/ c5 Y, E5 D% Q2 x. c
                   *    The user should not be able to use the ‘system’ until they have provided the  ; J9 q9 @% l& Q3 Z; k
                        correct user name and PIN combination. You should give them a second or  8 `( u: ^4 g. K' I/ a
                        third chance to get it right before shutting the ‘system’ down.   % e" a6 u' K" M' I" j* n5 s6 J+ G

0 E( F' r: Q& Y  # Z0 j7 A3 ], o/ v6 f1 q
                  4 M) K6 Q2 W: R
                ** You must use the user names and passwords provided in your individual  3 g7 f0 m$ @. x
. J# M7 v9 p8 M6 O- l4 A" w, e4 N. v
                data available from the Assignment 2 page on Vista (see requirement 5 below).  0 H; z+ N7 j/ N4 |
                The user names and passwords should be included in your code, and the output  / P+ ^+ e+ u  ^8 d2 X8 y( e' F6 q
                to the screen should prompt the user with the user names and passwords (for  " b. G( f' ?4 Y

$ j$ i( f" [& W. {; v                marking purposes).  3 \, ~" j  i  I/ W

5 P$ Z# N, [6 g: r                  ( L& K- f! [$ T1 h4 `4 F1 i  v( ?
             ' ]7 V, X# Y0 w( X* s! P6 g( m7 h
*    The interface should provide a menu so that the staff can:  * l7 o5 M8 X3 o
0 ^; o( }: y& n' X
                -    Perform a Repayment calculation  
; R' L/ M6 R0 v2 ?( F" w
2 e4 K( `# T5 U7 A                -    Print out to the screen the Repayment details  0 r0 X! _. t( I% |% V( L7 D8 z, V
5 _4 s7 M+ k: N/ t, x
                -     Change one, two, or all of the values for the current calculation  
4 Y+ t/ I+ x$ @% a$ D/ o; j
, ~- u# b. Q' C5 W8 R                -     Start a new calculation   
7 o; D. f5 Z# h! j- z
, U$ n" ]/ K, k+ E: O  S, S; H                -    Leave the program.  
7 {: Y/ l9 q& J. l3 ~The RepayCalc class: (Total maximum 10 marks available)  8 n6 X' ?. I9 K: g* g2 Y
+ L; P/ B9 n" U. k- v
     2.    Provide a method to accept three input values from the user:   
+ `. n1 H4 |/ r; ]0 k# {  o: u' ]: b1 n4 u9 h) v" Y# z% X$ Q
                -     the Amount to be Borrowed (to 2 decimal places, for example, 10550.00)  
# l7 X* t/ w9 s$ k$ ]2 g. o2 J! ^% i$ ?. u8 o6 C& `" o: L
                -     the Annual Interest Rate (to 2 decimal places, for example, 9.75)  ; }/ m+ d& \  c
8 L0 E0 t6 |- E0 ]8 r
                -     the Period of Repayment (in whole Years, that is, no fractions of a year)  / N4 n3 I2 ^* R
  U3 L. k  M% K9 g
      3.   Provide a method to print out to the screen the three input values (accepted in  
" R( K6 j  C9 P. j           requirement 2), plus the repayment calculations:  - g2 f  ~. p* A& b

0 I$ i* X$ j, ~  C1 G+ b: c                -     the Weekly repayments  
5 S9 e. J) b# [' I4 t% d# b, H9 U+ s! y( J- \4 J
                -     the Total repayment amount (Amount borrowed + Interest)  3 z2 t; y- t- G2 K# s

+ a* F& o- r, v# G+ k  i9 A* S  4 e3 ^( A6 x% @+ y' Y& |
, R! I# c" s/ n0 M" F9 J
The Borrow class: (Total maximum 40 marks available)   
$ B' c& t( O+ x  r2 e$ `4 Y( ]2 y- R2 _- a- Q" {+ @( d. G5 L
     4.    Provide methods to perform the following tasks:  
2 g4 S( y# D: A
& R5 \, \; T1 }- x( W* d                -     to calculate the weekly repayments ***  
$ T6 ?8 _- P2 g9 f+ w" J; L
0 U, l1 E/ @0 `0 k8 a6 N                -     to calculate the total repayment amount  3 K9 X5 K1 r3 m- ~- g* H

; n& n& K9 }1 C$ @! z* i                -     to return the amount borrowed  0 h. H7 l6 Y- `) g) B" ?( g$ R7 C6 Q( c' _
: w; ~& @1 ~" u2 T& S, Q
                -     to return the borrowing period in years  
% m1 E6 y2 \/ Z% q2 ^8 k- q. Y/ F0 e4 |5 Q% b3 t5 Z+ P- {
                -     to return the borrowing period in weeks  
* L  l1 w' D# B8 C) Z# d+ L* D3 C4 i- }- B$ P# F% H. u+ _
                -     to return the annual interest rate  6 Q/ i5 r* ^9 E) M) y
% `  S2 [) J: M! G/ ~. b4 D9 g. {
                -     to return the weekly repayments  
/ g. G* N; M4 ~! @5 T- C& }4 d6 T/ X0 |6 K* P
                -     to return the total repayment amount   
4 j# t. V0 a* \. ~  _3 J# R- @8 I
6 i6 q) `. {$ l& x& O3 _% f% `- J                -     to reset the loan amount  7 u( D6 y- I# Z. _2 S2 X
' t6 {- V& J0 `3 |8 F: _& J+ p, A! J
                -     to reset the annual interest rate  
/ G  @5 @+ i  m+ V# V. H! d* m, k' \+ i+ K5 b
                -     to reset the loan period (in years)   
, }! g" E8 l* c% W& x
3 V% ]; |; Z: t  T         m% p$ a# M# M6 M% y
2 u6 [+ V5 F1 {- t) L1 l
               
" a! g- T' c( g      
' Y) L# L7 P8 s0 k  q" P2 N              *** Use a simple interest calculation (not compound) formula, for example:   , _: e( o# D& U. w  E7 i! j2 o
       2 F8 m6 w$ [; \, ^
             weeklyRepayment = (borrowedAmount * 1 + (annualInterestRate *  
: |' m$ p4 v3 Q! }             numberOfYears )) / numberOfPayments;  , z* V! i& H6 \$ }* ?

. O* f2 W# a; s( `# E0 W3 R         
+ e* n  E0 \& E5 s; b* m4 L  O
& k5 Z) m' o: c9 d9 k3 [1 U      
/ I+ z/ ~* ^/ ]7 z& L, t3 M& w
9 F% {/ X- @( U9 z0 b1 H* EIndividual Data (Maximum 10 marks available)  ) O& i+ m' \1 v3 U# D) {+ s+ X

6 d3 g% k8 m; N$ D      5.   You will be given two Megalodon staff member user names and passwords, plus a set  ( y% N+ ^/ I5 O: }' W& T
           of data for each staff member to use to calculate repayment details. You will need to  
7 Z+ G, I. k  \$ i           log onto the BSA104 Assignment 2 page on Vista to generate your individual data  
/ M' L9 O6 t6 F: {; Y9 e& s% ~           and instructions for this requirement. You will need to use your University of  8 G4 {$ V$ z% W3 O& c
           Tasmania (UTas) student number.  
% V- \9 c. |9 Z8 E            
% S; I  d1 i; E+ U" U6 ?4 F
, m# i; F% y" K1 y( n1 Z                                                        Page 2 of 5  
5 R1 X# P2 U' F( ]6 E3 r; \  Q; N% Q" {+ o7 Q) I
For requirement 5 use the following data:( V* W/ M3 i" y" I, s* ?) y+ U9 [
4 F4 _* w/ E" B  _6 M, s# Q5 [2 Q
# Data Set 1:) \$ \% p1 r( ]: H5 s7 b% u7 D
! y8 m. d- l5 b$ |9 i
User name: JordanM* Q" e. J3 K+ \: I
Password:  Ferrari
' k3 @2 t+ b% l% L2 a5 S" V' tBorrowed: $ 749.95+ m" ]2 i3 V3 h7 C( T3 u
Interest:    15.0 %/ q$ W5 s; n# ?) O. I% r8 G. v: u
Years:      4
: F; y5 e; b7 ]5 P9 f2 W2 q) q+ `9 u. u$ Z( |, T0 d" H5 V
# Data Set 2:2 O9 g% E; V$ I& @0 V1 }! C

7 z) r, ~' \' qUser name: KimZ
# K1 b# T  K1 n( z, cPassword:  DimSim
2 Q, [6 P! X5 {* iBorrowed: $ 150500.25
* p. r( c( `0 h* {' r" m4 F3 jInterest:    5.5 %
& q% ?' z; l! Q" gYears:      7, m+ h0 X/ M  d
8 J$ T; w. o: D+ p3 O* k& l
[ 本帖最后由 wwwsnailcom 于 2006-5-24 02:15 AM 编辑 ]
 楼主| 发表于 2006-5-24 10:52:42 | 显示全部楼层
怎么也没有里我啊,高手来呀
回复

使用道具 举报

发表于 2006-5-24 13:01:55 | 显示全部楼层
哦 对不起 爱莫能助。
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 加入华同

本版积分规则

Archiver|手机版|小黑屋|华人同志

GMT+8, 2025-5-9 23:40 , Processed in 0.066333 second(s), 5 queries , Redis On.

Powered by Discuz! X3.5

© 2001-2025 Discuz! Team.

快速回复 返回顶部 返回列表