function charthe function char does the opposite


Function char:

The function char does the opposite; it converts from any number type to the type char:

>> char(numequiv)

ans =

a

As the letters of the alphabet are in order, the character 'b' has the equal value of 98, 'c' is 99, and so on. Math can be completed on characters. For illustration, to get the next character in the collating sequence, 1 can be added either to the character or the integer:

>> numequiv = double('a');

>> char(numequiv + 1)

ans =

b

>> 'a' + 2

ans =

99

 

 

Request for Solution File

Ask an Expert for Answer!!
Applications of MATLAB: function charthe function char does the opposite
Reference No:- TGS0174714

Expected delivery within 24 Hours