Index: [Article Count Order] [Thread]

Date:  Wed, 24 Mar 2004 12:47:34 +0900
Subject:  yIuWFNgyF 2004-11 z

@@@@@@@
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@@@@@@@@I@u@W@F@N@g@@y@@@@@
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@@@@@@@
@@@@@@@@@@@@@@@@@@@@@@@@@@No.39@2004/03/24

@I@N@D@E@X

yvO~OzR[hJ^wBlvO} [1]
yvO~OzC#wIuWFNgw [4]
yAP[gzCVXeE zg

1 s t 

yvO~OzR[hJ^wBlvO} [1]

 
AADave"Bl"ThomasR[hJ^M\v
BuR[hJ^HvvA[*1]
QlB

 J^: X[p[}[Pbgi [*2]
hJ^AfOvl(s)B

X[p[iAPBl198~B
AGB:
 * 198~A3289~(45liH)
 * 1kg500~(250gliH)
 * 21^_ (3iliH)

iA_\gglB
ApIp(ZAi)l
BAlY:
 * z[H 
 * [()H 
 * iL^(KvH)
 * di(cost)i(price)NXH
 * I100Aiu21^_vA
   ]H 

J^ZzIBAvvf
B2TlB

 J^W
 * CyfO
 * A@fO
 * foZ@Ll
 * fL^Z@Ll
 * fl

CyAF@A|CgB
JABB(v)

 This kata involves no coding....
uJ^R[fBOvBJ^
"coding-style kata""design-ish kata"AJ^
J^BAR[fBO
B

AUMLfAA
BJ^WufvB

MDAUML2.0us\fvsgA
oogB

AhLvO~OAIuWFNgw
T|[gLqA[us\
fvpvB
XNvgAW/sTCNZA
fOiKpvB
^PeXgt[[NpB
uhCv[*3]IAv[`lB

@fOJude:-)APythonRubyAJava
AJSR-241oGroovy[*4]
B

Martin FowleruZpAPXNvgB
v[*5]B

 \
J^uX[p[}[PbgivBM
fOJudeXNvgAB
FAJ^^CfXNvg
AIuWFNgyWB

J^uJe`bvv\BGL]`bN
B()

*1: http://objectclub.esm.co.jp/ml-arch/magazine/36.html

*2: http://www.pragprog.com/pragdave/Practices/Kata/KataOne.rdoc

*3: http://capsctrl.que.jp/kdmsnr/wiki/bliki/?DomainSpecificLanguage

*4: http://www.jcp.org/en/jsr/detail?id=241

*5: http://capsctrl.que.jp/kdmsnr/wiki/bliki/?LanguageForLearningObjects
_______________________________________________________________________
L]B
URLNbNAuvbZ[Wgp
uEU\[B
F
http://objectclub.esm.co.jp/cgi-bin/question.cgi?E004+1+0
F
http://objectclub.esm.co.jp/cgi-bin/question.cgi?E004+1+1
C}C`F
http://objectclub.esm.co.jp/cgi-bin/question.cgi?E004+1+2

2 n d 

yvO~OzC#wIuWFNgw [4]


LAJC#gIuWFNg
wiOOjbCyAeB

W
OANXIuWFNgiCX^XjwKB
AUEuJvZvwK
vB

W
  JvZNXupv_lA
    pNXGBAupv
    ]GlvO~OmFB
B

e
saAoAT[rX\v
OPlvB
vOMainClassMainSB
JvZNXAAccountARecordiNjA
pMainivO}jB
iupv_ldBA
AccountARecordNX\bh{upv
dvLqAJRXgN^
LqBAccountARecorduv_\
Bj
======================================================================
using System;
using System.Collections;
using System.Threading;
class MainClass
{
    public static void Main(string[] args)
    {
        Account account = new Account();
        account.Deposit(10000);
        account.Withdraw(9000);
        foreach( Record record in account.GetRecords() ){
            Console.WriteLine(record.ToString());
        }
    }
}
//NXB
//T[rXB
class Account
{
    EEE
    //RXgN^B@VKcB
    public Account() {EEE}
    //aB@acB
    public void Deposit(ulong money) {EEE}
    //oBocB
    //aczofalseB
    public bool Withdraw(ulong money) {EEE}
    //T[rXB
    public IList GetRecords() {EEE}
}
//T[rXNXB
class Record 
{
    EEE
    //RXgN^
    public Record(string message, ulong money, DateTime time) {EE}
    public override string ToString() {EEE}
}
======================================================================
MainvOmFBA
    Account account = new Account();
IuWFNgB
    account.Deposit(10000);
10000aB
    account.Withdraw(9000);         
9000oB
    foreach( Record record in account.GetRecords() ){
        Console.WriteLine(record.ToString());
    }
T[rX\B

EMainaT[rXGbZ[WAccount
@RecordAMainB
EMainZI
EMainWbNtiDepositAWithdrawj
  ez
EEEE
MainPH
JvZNXupv_B

AMainWbNLqA
EaGWbN
ET[rXcGWbN
ESt[Sf[^\
EEEE
lLqKvAMainGezB


sPvOAJvZupv
GlvOmFBJvZ
AEGBB
upvPoGvO
BilvOHHHj
AAccountARecorduv_JvZwK
vB

JvZ@EEEiIENAGAj
_______________________________________________________________________
L]B
URLNbNAuvbZ[Wgp
uEU\[B
F
http://objectclub.esm.co.jp/cgi-bin/question.cgi?E003+3+0
F
http://objectclub.esm.co.jp/cgi-bin/question.cgi?E003+3+1
C}C`F
http://objectclub.esm.co.jp/cgi-bin/question.cgi?E003+3+2
 
3 r d 

CVXeE zg

TuIuWFNgwyvzgB"IuWFNgw"
tBABAIuWFNgw
H

  I
     http://objectclub.esm.co.jp/cgi-bin/question.cgi?Z001+5+0
  IB
     http://objectclub.esm.co.jp/cgi-bin/question.cgi?Z001+5+1
  IB
     http://objectclub.esm.co.jp/cgi-bin/question.cgi?Z001+5+2
  ZpIB
     http://objectclub.esm.co.jp/cgi-bin/question.cgi?Z001+5+3
  vBB
     http://objectclub.esm.co.jp/cgi-bin/question.cgi?Z001+5+4
  IuWFNgwH
     http://objectclub.esm.co.jp/cgi-bin/question.cgi?Z001+5+5
  B
     http://objectclub.esm.co.jp/cgi-bin/question.cgi?Z001+5+6
  I
     editors@ObjectClub.esm.co.jp II

AP[gIuWFNgyHPJByB
AOuvO}DvJBB
http://www.objectclub.jp/ml-arch/magazine/question/index.html
------

WL

AWlB
}V[YBTuCVXeE zgv
GA}JB
XAA
BVAJ
icqjB
 
T
*** [}iij***
v_NgABXARcRci
Afv_NgB 
ij

------
 Az         [M
Z zM~AAhXX http://www.ObjectClub.jp/mlmagazine_help.html
Z AL   http://www.ObjectClub.jp/mlmagazine.html
 sFIuWFNgy http://www.ObjectClub.jp/
 W\F  
Copyright (c)2003-2004 IuWFNgy. All Rights Reserved.
powered by Eiwa System Management, Inc.