Professional Documents
Culture Documents
Implement a class BigInt to handle big integers more than what primitive integer data type can handle. The
BigInt class has the following properties:
1.
2.
3.
4.
5.
For testing
478637843647863473644374636666666666666666666678888888888888374364873483764346247324637463463463
746374643723888888888888888888888888888888888888888888887473777373737737377397238728932382738239
283823729893728888888888888888889999999999999333333333333330000000000000338237237278639872732732
68
+
837463476347836473647364736437437434737474346464664646438483483843887467347364734347367343777777
774343437474734773773477777777777777777773434737437374736366463438376374638943436373746637463746
73467346374634343434
=
478637843647863473644374636666666666666666666678888888888888374364873483764347084788113811299937
393739380161326323626363235353553535327372372732776356234838511721105081155175013072369857473013
057301507671506666666662323626327374736366462771709707972273436373746637801983971952103619076167
02
=================================================================
X=
834853478563475647534785645745467546785647856487564785648576478564756475647856456475647856478564
875647865467546756478564564785647865475646547576457846574574658475634754658475485457468576464546
547854687564756478564785647547563
Y=
984574857489754985734567847854578645786474774757474774747477474747477747747758586886696979797999
483838382828884884854857847887584845847585845485488887485794584574875894847584758945894785748958
9454854758475984758945487589484854787858485848548581
X-Y =
-98457485748975498565108249999823108103299621018292802006891268909872126918290093903022133223321
383819081804323702836729306134083017019972938900692410093822992981723011019012729309833131028311
13969397289899520212397632901920098309293700201001018
=======================================================================
478637843647863473644374636666666666666666666678888888888888374364873483764347084788113811299937
393739380161326323626363235353553535327372372732776356234838511721105081155175013072369857473013
057301507671506666666662323626327374736366462771709707972273436
*
478637843647863473644374636666666666666666666678888888888888374364873483764347084788113811299937
393739380161326323626363235353553535327372372732776356234838511721105081155175013072369857473013
0573015076715066666666623236263273747363664627717097
=
229094185371876600586988730838639396129844959057665380622502836814420902909611948819734064497003
594531743738974016362249163813696756714022580301674094891772453138317306201271869067417315557101
243879943891067034092029356394079787933119174808107152490645820608336449584660445531761026339646
362479528932331981743002587424297733157797176062500598027450951745115633075076647133468542967410
370181355033007670265539311690343064791416858453462332969490692631534049731987872705780247406050
5153902741736135292
===============================================================
856475647856436874637446845358746547564876347463487365777777777777777777777777777893458476547854
547687857845648756475475647577475684756746547854785685847564647857454658746578465847854674754875
478854754674545677777777777777485448348384478564745745674564754785475478547854785648758957485748
95478954
/
48754785467854657478546784564875764574564785457
Quotient =
175670068002070140439198356054298141685156710216477749426267573410814788141003695541891737258157
904017691083276013893655595601247849386275857984279818719100456478307995233724171601432074058736
9188197843524091592570620730425932404472933240241924429746
Remainder =
6305117842137298975600274754671050757336475032
To add and subtract complex numbers: Simply combine like terms. For example, (3 2i) (2 6i) = 3 2i 2 + 6i = 1 +
4i.
To divide complex numbers: Multiply both the numerator and the denominator by the conjugate of the denominator and
The complex conjugate of 3 4i is 3 + 4i. Follow these steps to finish the problem:
1.
2.