Skip to content

An efficient solution to the classic josephus problem ( step = 2 )

Notifications You must be signed in to change notification settings

Kallachi10/josephus-problem

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 

Repository files navigation

josephus-problem

  • Self-developed solution for the classic josephus problem(step = 2).
  • The implementation follows an iterative solution.
  • input : initial number of people.
  • output : index of the surviving person.
  • Time complexity : O(log(n)).

About

An efficient solution to the classic josephus problem ( step = 2 )

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages