CSCI 235 — Ultimate review

The homeworks

The decoding assignment

This will not be on the upcoming exams.

	.file	"testit.c"
	.text
	.globl	un_c
	.type	un_c, @function
un_c:
.LFB0:
	.cfi_startproc
	movl	$0, %eax
	jmp	.L2
.L3:
	movslq	%eax, %rdx
	addl	%eax, (%rdi,%rdx,4)
	addl	$1, %eax
.L2:
	cmpl	%esi, %eax
	jl	.L3
	rep ret
	.cfi_endproc
.LFE0:
	.size	un_c, .-un_c
	.ident	"GCC: (Ubuntu 4.8.4-2ubuntu1~14.04.3) 4.8.4"
	.section	.note.GNU-stack,"",@progbits

The C program — version 2

Start with homework version 1 solution.

Add something like this.

  // This section is for Part 2 of the assignment (HW7)
  char name[51] ;
  int hour ;
  int minute ;

  while(fscanf(fileIn, "%50s %d:%d", name, &hour, &minute) == 3) {
    fprintf(fileOut, "%-50s %02d:%02d \n", name, hour, minute) ;
  }
  fclose(fileIn);
  fclose(fileOut);
  return 0 ;

Expected access time

Be sure to complete the expected time homework before the exams. ECON 120 students call it “expected return”.

Some things you just have to know

Getting ready for the prefinal and final

Review the exams!