/
*
*
*
* Pace University
* Fall 2016
* Algorithms and Theory of Computing
*
* Course: CS 608 CRN 73103
* Author: Rakesh Parappa
* Collaborators: NONE
* References: None
*
* Assignment: Assignment #1
* Problem: Maximum Subarray Problem using Brute Force i
/
*
*
*
* Pace University
* Fall 2016
* Algorithms and Theory of Computing
*
* Course: CS 608 CRN 73103
* Author: Rakesh Parappa
* Collaborators: NONE
* References: None
*
* Assignment: Assignment #1
* Problem: Maximum Subarray Problem using Divide and Co
import java.util.Random;
import java.util.Scanner;
public class LibrarySort cfw_
public static void main(String[] args) cfw_
int n;
Scanner key = new Scanner(System.in);
System.out.println("Provide the length of the input array");
n = key.nextInt();
int[]
/
*
*
*
* Pace University
* Fall 2016
* Algorithms and Theory of Computing
*
* Course: CS 608 CRN 73103
* Author: Rakesh Parappa
* Collaborators: NONE
* References: None
*
* Assignment: Assignment #1
* Problem: Maximum Subarray Problem using Brute Force
*
CS608 Algorithms and Computing Theory
Homework 1
Mayur Nayak (UID: U01177266)
1. (
)
for n 1
Proof: Base step: If N = 1, then
=1
Inductive step: Assume (
Show (N+1) case (
(
)
(
)
)
(
=
=
=
=
2.
Proof: Base step: if n=0, then
Inductive step: Assume,
Homework 3
Alexander Gazarov
CS 608 Algorithms and Compu ng Theory
February 19, 2013
1. Come up with a divide and conquer algorithm. Use the template to describe and analyze the
algorithm.
Input: a and n
Output: ni=1 a
Algorithm:
a
+a+
cfw_z + a
n

a
+
Assignment 4
Part 1
Testing of Count method for number of a or A in the string.
Result
Testing of Square method by providing a number
Result
Testing of Divide method by providing two numbers.
Result
Testing all the methods at once using Junit Test Suite.