Yurttas/PL/OOL/Cplusplus/F/03/01/01/00/C.cpp

From ZCubes Wiki
Revision as of 22:52, 6 November 2013 by MassBot1 (talk | contribs) (Created page with "<syntaxhighlight lang="cpp" line start="1" enclose="div">/* Copyright(C) 1998 All Rights Reserved. Salih Yurttas, ZCubes, BitsOfCode Software Systems, Inc.. Perm...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
 1/*
 2   Copyright(C) 1998
 3   All Rights Reserved. Salih Yurttas, ZCubes, BitsOfCode Software Systems, Inc..
 4
 5   Permission to use, copy, modify, and distribute this
 6   software and its documentation for EDUCATIONAL purposes
 7   and without fee is hereby granted provided that this
 8   copyright notice appears in all copies.
 9
10   date   : January 1, 1998.
11   author : Salih Yurttas.
12
13   C.cpp
14*/
15
16
17#include "C.h"
18
19C::
20C(const int i,
21  const int j) : i1(i),
22                 i2(j) {
23}
24
25C::
26C(const C& c) : i1(c.i1),
27                i2(c.i2) {
28}
29
30int
31C::
32get_i1() const {
33  return i1;
34}
35
36int
37C::
38get_i2() const {
39  return i2;
40}
41
42void
43C::
44set_i1_i2(const int i) {
45  i1=i;
46  i2=i;
47}
48
49ostream& operator<<(ostream& os,
50                    const C& c) {
51  os << endl;
52  os << c.i1 << endl;
53  os << c.i2 << endl;
54  os << endl;
55
56  return os;
57}