• Home
  • Raw
  • Download

Lines Matching refs:v1

44   int v1[3] = { 0, 1, 2 };  in prevprm0()  local
45 prev_permutation(v1, v1 + 3); in prevprm0()
47 CPPUNIT_ASSERT(v1[0]==2); in prevprm0()
48 CPPUNIT_ASSERT(v1[1]==1); in prevprm0()
49 CPPUNIT_ASSERT(v1[2]==0); in prevprm0()
53 vector <int> v1(3); in prevprm1() local
54 __iota(v1.begin(), v1.end(), 0); in prevprm1()
56 prev_permutation(v1.begin(), v1.end()); in prevprm1()
57 CPPUNIT_ASSERT(v1[0]==2); in prevprm1()
58 CPPUNIT_ASSERT(v1[1]==1); in prevprm1()
59 CPPUNIT_ASSERT(v1[2]==0); in prevprm1()
60 prev_permutation(v1.begin(), v1.end()); in prevprm1()
61 CPPUNIT_ASSERT(v1[0]==2); in prevprm1()
62 CPPUNIT_ASSERT(v1[1]==0); in prevprm1()
63 CPPUNIT_ASSERT(v1[2]==1); in prevprm1()
64 prev_permutation(v1.begin(), v1.end()); in prevprm1()
65 CPPUNIT_ASSERT(v1[0]==1); in prevprm1()
66 CPPUNIT_ASSERT(v1[1]==2); in prevprm1()
67 CPPUNIT_ASSERT(v1[2]==0); in prevprm1()
68 prev_permutation(v1.begin(), v1.end()); in prevprm1()
69 CPPUNIT_ASSERT(v1[0]==1); in prevprm1()
70 CPPUNIT_ASSERT(v1[1]==0); in prevprm1()
71 CPPUNIT_ASSERT(v1[2]==2); in prevprm1()
72 prev_permutation(v1.begin(), v1.end()); in prevprm1()
73 CPPUNIT_ASSERT(v1[0]==0); in prevprm1()
74 CPPUNIT_ASSERT(v1[1]==2);// in prevprm1()
75 CPPUNIT_ASSERT(v1[2]==1); in prevprm1()
76 prev_permutation(v1.begin(), v1.end()); in prevprm1()
77 CPPUNIT_ASSERT(v1[0]==0); in prevprm1()
78 CPPUNIT_ASSERT(v1[1]==1); in prevprm1()
79 CPPUNIT_ASSERT(v1[2]==2); in prevprm1()
80 prev_permutation(v1.begin(), v1.end()); in prevprm1()
81 CPPUNIT_ASSERT(v1[0]==2); in prevprm1()
82 CPPUNIT_ASSERT(v1[1]==1); in prevprm1()
83 CPPUNIT_ASSERT(v1[2]==0); in prevprm1()
84 prev_permutation(v1.begin(), v1.end()); in prevprm1()
85 CPPUNIT_ASSERT(v1[0]==2); in prevprm1()
86 CPPUNIT_ASSERT(v1[1]==0); in prevprm1()
87 CPPUNIT_ASSERT(v1[2]==1); in prevprm1()
88 prev_permutation(v1.begin(), v1.end()); in prevprm1()
89 CPPUNIT_ASSERT(v1[0]==1); in prevprm1()
90 CPPUNIT_ASSERT(v1[1]==2); in prevprm1()
91 CPPUNIT_ASSERT(v1[2]==0); in prevprm1()
95 vector <int> v1(3); in prevprm2() local
96 __iota(v1.begin(), v1.end(), 0); in prevprm2()
98 prev_permutation(v1.begin(), v1.end(), greater<int>()); in prevprm2()
99 CPPUNIT_ASSERT(v1[0]==0); in prevprm2()
100 CPPUNIT_ASSERT(v1[1]==2); in prevprm2()
101 CPPUNIT_ASSERT(v1[2]==1); in prevprm2()
102 prev_permutation(v1.begin(), v1.end(), greater<int>()); in prevprm2()
103 CPPUNIT_ASSERT(v1[0]==1); in prevprm2()
104 CPPUNIT_ASSERT(v1[1]==0); in prevprm2()
105 CPPUNIT_ASSERT(v1[2]==2); in prevprm2()
106 prev_permutation(v1.begin(), v1.end(), greater<int>()); in prevprm2()
107 CPPUNIT_ASSERT(v1[0]==1); in prevprm2()
108 CPPUNIT_ASSERT(v1[1]==2); in prevprm2()
109 CPPUNIT_ASSERT(v1[2]==0); in prevprm2()
110 prev_permutation(v1.begin(), v1.end(), greater<int>()); in prevprm2()
111 CPPUNIT_ASSERT(v1[0]==2); in prevprm2()
112 CPPUNIT_ASSERT(v1[1]==0); in prevprm2()
113 CPPUNIT_ASSERT(v1[2]==1); in prevprm2()
114 prev_permutation(v1.begin(), v1.end(), greater<int>()); in prevprm2()
115 CPPUNIT_ASSERT(v1[0]==2); in prevprm2()
116 CPPUNIT_ASSERT(v1[1]==1); in prevprm2()
117 CPPUNIT_ASSERT(v1[2]==0); in prevprm2()
118 prev_permutation(v1.begin(), v1.end(), greater<int>()); in prevprm2()
119 CPPUNIT_ASSERT(v1[0]==0); in prevprm2()
120 CPPUNIT_ASSERT(v1[1]==1); in prevprm2()
121 CPPUNIT_ASSERT(v1[2]==2); in prevprm2()
122 prev_permutation(v1.begin(), v1.end(), greater<int>()); in prevprm2()
123 CPPUNIT_ASSERT(v1[0]==0); in prevprm2()
124 CPPUNIT_ASSERT(v1[1]==2); in prevprm2()
125 CPPUNIT_ASSERT(v1[2]==1); in prevprm2()
126 prev_permutation(v1.begin(), v1.end(), greater<int>()); in prevprm2()
127 CPPUNIT_ASSERT(v1[0]==1); in prevprm2()
128 CPPUNIT_ASSERT(v1[1]==0); in prevprm2()
129 CPPUNIT_ASSERT(v1[2]==2); in prevprm2()
130 prev_permutation(v1.begin(), v1.end(), greater<int>()); in prevprm2()
131 CPPUNIT_ASSERT(v1[0]==1); in prevprm2()
132 CPPUNIT_ASSERT(v1[1]==2); in prevprm2()
133 CPPUNIT_ASSERT(v1[2]==0); in prevprm2()
137 int v1[3] = { 0, 1, 2 }; in nextprm0() local
138 next_permutation(v1, v1 + 3); in nextprm0()
140 CPPUNIT_ASSERT(v1[0]==0); in nextprm0()
141 CPPUNIT_ASSERT(v1[1]==2); in nextprm0()
142 CPPUNIT_ASSERT(v1[2]==1); in nextprm0()
146 vector <int> v1(3); in nextprm1() local
147 __iota(v1.begin(), v1.end(), 0); in nextprm1()
149 next_permutation(v1.begin(), v1.end()); in nextprm1()
150 CPPUNIT_ASSERT(v1[0]==0); in nextprm1()
151 CPPUNIT_ASSERT(v1[1]==2); in nextprm1()
152 CPPUNIT_ASSERT(v1[2]==1); in nextprm1()
153 next_permutation(v1.begin(), v1.end()); in nextprm1()
154 CPPUNIT_ASSERT(v1[0]==1); in nextprm1()
155 CPPUNIT_ASSERT(v1[1]==0); in nextprm1()
156 CPPUNIT_ASSERT(v1[2]==2); in nextprm1()
157 next_permutation(v1.begin(), v1.end()); in nextprm1()
158 CPPUNIT_ASSERT(v1[0]==1); in nextprm1()
159 CPPUNIT_ASSERT(v1[1]==2); in nextprm1()
160 CPPUNIT_ASSERT(v1[2]==0); in nextprm1()
161 next_permutation(v1.begin(), v1.end()); in nextprm1()
162 CPPUNIT_ASSERT(v1[0]==2); in nextprm1()
163 CPPUNIT_ASSERT(v1[1]==0); in nextprm1()
164 CPPUNIT_ASSERT(v1[2]==1); in nextprm1()
165 next_permutation(v1.begin(), v1.end()); in nextprm1()
166 CPPUNIT_ASSERT(v1[0]==2); in nextprm1()
167 CPPUNIT_ASSERT(v1[1]==1); in nextprm1()
168 CPPUNIT_ASSERT(v1[2]==0); in nextprm1()
169 next_permutation(v1.begin(), v1.end()); in nextprm1()
170 CPPUNIT_ASSERT(v1[0]==0); in nextprm1()
171 CPPUNIT_ASSERT(v1[1]==1); in nextprm1()
172 CPPUNIT_ASSERT(v1[2]==2); in nextprm1()
173 next_permutation(v1.begin(), v1.end()); in nextprm1()
174 CPPUNIT_ASSERT(v1[0]==0); in nextprm1()
175 CPPUNIT_ASSERT(v1[1]==2); in nextprm1()
176 CPPUNIT_ASSERT(v1[2]==1); in nextprm1()
177 next_permutation(v1.begin(), v1.end()); in nextprm1()
178 CPPUNIT_ASSERT(v1[0]==1); in nextprm1()
179 CPPUNIT_ASSERT(v1[1]==0); in nextprm1()
180 CPPUNIT_ASSERT(v1[2]==2); in nextprm1()
181 next_permutation(v1.begin(), v1.end()); in nextprm1()
182 CPPUNIT_ASSERT(v1[0]==1); in nextprm1()
183 CPPUNIT_ASSERT(v1[1]==2); in nextprm1()
184 CPPUNIT_ASSERT(v1[2]==0); in nextprm1()
188 vector <char> v1(3); in nextprm2() local
189 __iota(v1.begin(), v1.end(), 'A'); in nextprm2()
191 next_permutation(v1.begin(), v1.end(), less<char>()); in nextprm2()
192 CPPUNIT_ASSERT(v1[0]=='A'); in nextprm2()
193 CPPUNIT_ASSERT(v1[1]=='C'); in nextprm2()
194 CPPUNIT_ASSERT(v1[2]=='B'); in nextprm2()
195 next_permutation(v1.begin(), v1.end(), less<char>()); in nextprm2()
196 CPPUNIT_ASSERT(v1[0]=='B'); in nextprm2()
197 CPPUNIT_ASSERT(v1[1]=='A'); in nextprm2()
198 CPPUNIT_ASSERT(v1[2]=='C'); in nextprm2()
199 next_permutation(v1.begin(), v1.end(), less<char>()); in nextprm2()
200 CPPUNIT_ASSERT(v1[0]=='B'); in nextprm2()
201 CPPUNIT_ASSERT(v1[1]=='C'); in nextprm2()
202 CPPUNIT_ASSERT(v1[2]=='A'); in nextprm2()
203 next_permutation(v1.begin(), v1.end(), less<char>()); in nextprm2()
204 CPPUNIT_ASSERT(v1[0]=='C'); in nextprm2()
205 CPPUNIT_ASSERT(v1[1]=='A'); in nextprm2()
206 CPPUNIT_ASSERT(v1[2]=='B'); in nextprm2()
207 next_permutation(v1.begin(), v1.end(), less<char>()); in nextprm2()
208 CPPUNIT_ASSERT(v1[0]=='C'); in nextprm2()
209 CPPUNIT_ASSERT(v1[1]=='B'); in nextprm2()
210 CPPUNIT_ASSERT(v1[2]=='A'); in nextprm2()
211 next_permutation(v1.begin(), v1.end(), less<char>()); in nextprm2()
212 CPPUNIT_ASSERT(v1[0]=='A'); in nextprm2()
213 CPPUNIT_ASSERT(v1[1]=='B'); in nextprm2()
214 CPPUNIT_ASSERT(v1[2]=='C'); in nextprm2()
215 next_permutation(v1.begin(), v1.end(), less<char>()); in nextprm2()
216 CPPUNIT_ASSERT(v1[0]=='A'); in nextprm2()
217 CPPUNIT_ASSERT(v1[1]=='C'); in nextprm2()
218 CPPUNIT_ASSERT(v1[2]=='B'); in nextprm2()
219 next_permutation(v1.begin(), v1.end(), less<char>()); in nextprm2()
220 CPPUNIT_ASSERT(v1[0]=='B'); in nextprm2()
221 CPPUNIT_ASSERT(v1[1]=='A'); in nextprm2()
222 CPPUNIT_ASSERT(v1[2]=='C'); in nextprm2()
223 next_permutation(v1.begin(), v1.end(), less<char>()); in nextprm2()
224 CPPUNIT_ASSERT(v1[0]=='B'); in nextprm2()
225 CPPUNIT_ASSERT(v1[1]=='C'); in nextprm2()
226 CPPUNIT_ASSERT(v1[2]=='A'); in nextprm2()