Skip to content

dsover/CodeDemo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CodeDemo

Author: Alex Sover

This project was created in Java because I wanted an OO language for the prime number generator. This function can be computationally intense and using the singleton design pattern could prevent it from being created a multitude of times. Also, it was helpful in separating the secret from the code body.

Demo Code for Code Exercise

Coding Exercise: You are given a Secret which encapsulates a function that accepts a single integer parameter and returns an integer. In Java or a language of your choice, write an application that determines if Secret is an additive function secret(x+y) = secret(x) + secret(y) for all prime numbers less than N where N is a given integer.

Assume you are going to ship this code. Use your judgment to determine what you need to include. Document any assumptions or choices you make in your implementation. Also, include an explanation of your choice of language.

Please share your solution and any associated code or documentation as a public Github repository.

About

Demo Code for Code Exercise

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages