Script started on Fri 22 Jan 2016 02:12:33 PM EST
ppannuto@C4CS-W16-patbook:~
$ $ cd hwlec3/
ppannuto@C4CS-W16-patbook:~/lec3
$ ls
a.out  math.c
ppannuto@C4CS-W16-patbook:~/lec3
$ cp math.c math2.c
ppannuto@C4CS-W16-patbook:~/lec3
$ vi -p math*
2 files to edit
th2.c" 5L, 59C"math.c" math2.c  math.c                                    X  1 #include <stdio.h>
  2 
  3 int main() {
  4 "2+2=%d\n", 4);
  5 }
~                                                   ath2.c (~/lec3) (1 of 2) - VIMath2.c(+a tmath2.c  math.c  X5ath2.c + (~/lec3) (1 of 2) - VIMath2.c-- INSERT --  6 }"Thats''s not how math owworks\n"(ath2.c" 6L, 99C written 1 #include <stdio.h>
  2 
  3 int main() {
  4 "2+2=%d\n", 4);
  5 }
~                                                   ath.c (~/lec3) (2 of 2) - VIMath.cppannuto@C4CS-W16-patbook:~/lec3
$ $ $ pannuto@C4CS-W16-patbook:~/lec3
$ ccat# CREATE THIS FILE ON YOUR MACHINE:
ppannuto@C4CS-W16-patbook:~/lec3
$ cat pannuto@C4CS-W16-patbook:~/lec3
$ cat PSQ=1="$ $""
$ ath*[C[C# CREATE THIS FILE ON YOUR MACHINE:
$ cat mathath.c 
#include <stdio.h>

int main() {
	printf("2+2=%d\n", 4);
}
$ exedit a.out 
=00000000   7F 45 4C 46  02 01 01 00  00 00 00 00  00 00 00 00  .ELF............
00000010   02 00 3E 00  01 00 00 00  40 04 40 00  00 00 00 00  ..>.....@.@.....
00000020   40 00 00 00  00 00 00 00  F0 19 00 00  00 00 00 00  @...............
00000030   00 00 00 00  40 00 38 00  09 00 40 00  1E 00 1B 00  ....@.8...@.....
00000040   06 00 00 00  05 00 00 00  40 00 00 00  00 00 00 00  ........@.......
00000050   40 00 40 00  00 00 00 00  40 00 40 00  00 00 00 00  @.@.....@.@.....
00000060   F8 01 00 00  00 00 00 00  F8 01 00 00  00 00 00 00  ................
00000070   08 00 00 00  00 00 00 00  03 00 00 00  04 00 00 00  ................
---  a.out12H




39Hsearching...33H(press any key to cancel)
39H8 85 C0 74  0B 5D BF 40  .t......H..t.].@
000004E0   10 60 00 FF  E0 0F 1F 00  5D C3 66 0F  1F 44 00 00  .`......].f..D..
000004F0   80 3D 49 0B  20 00 00 75  11 55 48 89  E5 E8 6E FF  .=I. ..u.UH...n.
00000500   FF FF 5D C6  05 36 0B 20  00 01 F3 C3  0F 1F 40 00  ..]..6. ......@.
00000510   BF 20 0E 60  00 48 83 3F  00 75 05 EB  93 0F 1F 00  . .`.H.?.u......
28H48 85 C0  74 F1 55 48  89 E5 FF D69HH..t.UH
0575H.
**24HC51H29Hanges (Yes/No/Cancel) ?

2+2=5
$ hexi 
=00000000   23 69 6E 63  6C 75 64 65  20 3C 73 74  64 69 6F 2E  #include <stdio.
00000010   68 3E 0A 0A  69 6E 74 20  6D 61 69 6E  28 29 20 7B  h>..int main() {
00000020   0A 09 70 72  69 6E 74 66  28 22 32 2B  32 3D 25 64  ..printf("2+2=%d
00000030   5C 6E 22 2C  20 34 29 3B  0A 7D 0A64H\n", 4);.}.
00000040
00000050
00000060
00000070
---  math.c12H




00000020   0A 09 70 72  69 6E 74 66  28 22 32 2B  32 3D 25 64  ..printf("2+2=%d
00000030   5C 6E 22 2C  20 34 29 3B  0A 7D 0A64H\n", 4);.}.
00000040
00000050ath.c 
59

?
?
?
hlep   elp
?
.
}
1
#include <stdio.h>
2

3
int main() {
4
	printf("2+2=%d\n", 4);
5
}
6
?
.
}

?
.
}
-
	printf("2+2=%d\n", 4);
-
int main() {
a
// Hellow, I'm a comment
// Stop
//w  what


.
.

1
#include <stdio.h>
2

3
int main() {
4
// Hellow, I'm a comment
5
// Stop
6
// what
7

8

9
	printf("2+2=%d\n", 4);
q
?
q
$ ath.c 
59
> ,p
#include <stdio.h>

int main() {
	printf("2+2=%d\n", 4);
}
> 4
	printf("2+2=%d\n", 4);
> .
	printf("2+2=%d\n", 4);
> s/4/5
	printf("2+2=%d\n", 5);
> a
printf("that's not math\n");

.
> ,p
#include <stdio.h>

int main() {
	printf("2+2=%d\n", 5);
printf("that's not math\n");

}
> 6d
> ,p
#include <stdio.h>

int main() {
	printf("2+2=%d\n", 5);
printf("that's not math\n");
}
> 5
printf("that's not math\n");
> 5s/print/	print/ f t / 
	printf("that's not math\n");
> . ,p
#include <stdio.h>

int main() {
	printf("2+2=%d\n", 5);
	printf("that's not math\n");
}
> w
89
> q
$ PS!=1="prompt> "
prompt> prompt> exit

Script done on Fri 22 Jan 2016 03:24:01 PM EST