Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Problem 1262. Convert elements in numeric array into different class

Write a function that converts elements in a numeric array into a different class. Example:

a = [1:5]; % class: double
b = convertto(a,'uint32');
b =
         1  2  3  4  5
class(b)
  ans =
  uint32

Tags

Problem Group

Solution Statistics

30 correct solutions 25 incorrect solutions
Last solution submitted on Sep 14, 2014

Problem Comments