Cody Problem 1477 asks us to determine the nth digit of the Champernowne constant, whose decimal digits are formed by concatenating all of the positive integers--i.e., 0.12345678910111213...
This problem deals with the Copeland-Erdos constant, whose decimal digits are formed by concatenating all of the primes --i.e., 0.2357111317192329...
Return the digits of the Copeland-Erdos constant specified by the input vector. For example, the command
CopelandErdosDigit(1:8)
should return
2 3 5 7 1 1 1 3
Solution Stats
Problem Comments
Solution Comments
Show comments
Loading...
Problem Recent Solvers40
Suggested Problems
-
Given an unsigned integer x, find the largest y by rearranging the bits in x
2070 Solvers
-
Test if a Number is a Palindrome without using any String Operations
258 Solvers
-
Compute a dot product of two vectors x and y
1057 Solvers
-
945 Solvers
-
2354 Solvers
More from this Author328
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!