1. Engineering
  2. Computer Science
  3. 3 write a function that converts an array of decimal...

Question: 3 write a function that converts an array of decimal...

Question details

3. Write a function that converts an array of decimal digits into a natural number. It should have the signature function x = digits-to-uint (X) where x is a natural number and X is an array of natural numbers between 0 and 9. For example, digits to_uint([1 2 3 4 5]) outputs ans = 12345 Show the results for format long e; digits_to uint([9 00719 92 5 4 74099 2]) digits_to uint([9 0 07 19925 474 0 99 3]) digits to_uint ([9 0 07199 254740 9 9 4]) Explain why two of the three outputs are equal

Solution by an expert tutor
Blurred Solution
This question has been solved
Subscribe to see this solution