summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--6p18.cpp6
-rw-r--r--6p19.cpp22
-rw-r--r--6p20.cpp9
3 files changed, 31 insertions, 6 deletions
diff --git a/6p18.cpp b/6p18.cpp
index 58d5fbf..1d0bc41 100644
--- a/6p18.cpp
+++ b/6p18.cpp
@@ -1,12 +1,14 @@
-#include <iostream>
/*
*
- * Description
+ * 6.18
*
*
*/
int main () {
+
+ // bool compare(matrix &rm1, matrix &rm2);
+ // std::vector<int>::iterator change_val(int i, std::vector<int>::iterator iter);
return 0;
}
diff --git a/6p19.cpp b/6p19.cpp
index 58d5fbf..af813f4 100644
--- a/6p19.cpp
+++ b/6p19.cpp
@@ -1,12 +1,30 @@
-#include <iostream>
/*
*
- * Description
+ * 6.19
*
*
*/
int main () {
+
+ /*
+ double calc(double);
+ int count(const string &, char);
+ int sum(vector<int>::iterator, vector<int>::iterator, int);
+ vector<int> vec(10);
+
+ (a)
+ calc(23.4, 55.1); // illegal, only 1 argument
+
+ (b)
+ count("abcda", ’a’); // legal
+
+ (c)
+ calc(66); // legal
+
+ (d)
+ sum(vec.begin(), vec.end(), 3.8); // legal
+ */
return 0;
}
diff --git a/6p20.cpp b/6p20.cpp
index 58d5fbf..c2b0b0b 100644
--- a/6p20.cpp
+++ b/6p20.cpp
@@ -1,12 +1,17 @@
-#include <iostream>
/*
*
- * Description
+ * 6.20
*
*
*/
int main () {
+
+ /*
+ We should do it when we only need to read the data.
+ There is no point accidentally writing to something we did not intend to write to.
+ Because if we had used const we would not be allowed to.
+ */
return 0;
}