1 | #include <rf_core.hh> |
---|
2 | #include <refal/StdIO.hh> |
---|
3 | #include <refal/Arithm.hh> |
---|
4 | |
---|
5 | namespace refal |
---|
6 | { |
---|
7 | |
---|
8 | using namespace rfrt; |
---|
9 | |
---|
10 | namespace rem |
---|
11 | { |
---|
12 | |
---|
13 | static const Expr _c_0 = ShortInt::create_expr (-23); |
---|
14 | |
---|
15 | static const Expr _c_1 = ShortInt::create_expr (-11); |
---|
16 | |
---|
17 | static const Expr _c_2 = ShortInt::create_expr (-2147483647); |
---|
18 | |
---|
19 | static const Expr _c_3 = ShortInt::create_expr (2147483647); |
---|
20 | |
---|
21 | static const Expr _c_4 = Integer::create_expr ("2147483648"); |
---|
22 | |
---|
23 | static const Expr _c_5 = ShortInt::create_expr (2); |
---|
24 | |
---|
25 | static const Expr _c_6 = ShortInt::create_expr (2222222); |
---|
26 | |
---|
27 | static const Expr _c_7 = ShortInt::create_expr (22345); |
---|
28 | |
---|
29 | static const Expr _c_8 = Integer::create_expr ("-2147483648"); |
---|
30 | |
---|
31 | static const Expr _c_9 = Integer::create_expr ("-2147483649"); |
---|
32 | |
---|
33 | static const Expr _c_10 = Integer::create_expr ("-21474836481234567890786543"); |
---|
34 | |
---|
35 | static const Expr _c_11 = ShortInt::create_expr (-2); |
---|
36 | |
---|
37 | RF_FUNC (Main, (), (RF_RES _v_res1)) |
---|
38 | { |
---|
39 | Expr _v_Rem1; |
---|
40 | RF_CALL (Arithm::Rem, (_c_0, _c_1), (_v_Rem1)); |
---|
41 | RF_CALL (StdIO::PrintLN, (_v_Rem1), ()); |
---|
42 | Expr _v_Rem2; |
---|
43 | RF_CALL (Arithm::Rem, (_c_2, _c_2), (_v_Rem2)); |
---|
44 | RF_CALL (StdIO::PrintLN, (_v_Rem2), ()); |
---|
45 | Expr _v_Rem3; |
---|
46 | RF_CALL (Arithm::Rem, (_c_3, _c_2), (_v_Rem3)); |
---|
47 | RF_CALL (StdIO::PrintLN, (_v_Rem3), ()); |
---|
48 | Expr _v_Rem4; |
---|
49 | RF_CALL (Arithm::Rem, (_c_2, _c_3), (_v_Rem4)); |
---|
50 | RF_CALL (StdIO::PrintLN, (_v_Rem4), ()); |
---|
51 | Expr _v_Rem5; |
---|
52 | RF_CALL (Arithm::Rem, (_c_3, _c_3), (_v_Rem5)); |
---|
53 | RF_CALL (StdIO::PrintLN, (_v_Rem5), ()); |
---|
54 | Expr _v_Rem6; |
---|
55 | RF_CALL (Arithm::Rem, (_c_4, _c_5), (_v_Rem6)); |
---|
56 | RF_CALL (StdIO::PrintLN, (_v_Rem6), ()); |
---|
57 | Expr _v_Rem7; |
---|
58 | RF_CALL (Arithm::Rem, (_c_4, _c_6), (_v_Rem7)); |
---|
59 | RF_CALL (StdIO::PrintLN, (_v_Rem7), ()); |
---|
60 | Expr _v_Rem8; |
---|
61 | RF_CALL (Arithm::Rem, (_c_7, _c_8), (_v_Rem8)); |
---|
62 | RF_CALL (StdIO::PrintLN, (_v_Rem8), ()); |
---|
63 | Expr _v_Rem9; |
---|
64 | RF_CALL (Arithm::Rem, (_c_9, _c_4), (_v_Rem9)); |
---|
65 | RF_CALL (StdIO::PrintLN, (_v_Rem9), ()); |
---|
66 | Expr _v_Rem10; |
---|
67 | RF_CALL (Arithm::Rem, (_c_10, _c_11), (_v_Rem10)); |
---|
68 | RF_CALL (StdIO::PrintLN, (_v_Rem10), ()); |
---|
69 | _v_res1 = empty; |
---|
70 | } |
---|
71 | RF_END |
---|
72 | |
---|
73 | } |
---|
74 | |
---|
75 | rfrt::Entry rf_entry (rem::Main); |
---|
76 | |
---|
77 | } |
---|