Strcat function - concatenation, MATLAB in Mathematics

Strcat function - Concatenation:

The strcat function, though, will eliminate the trailing blanks from strings before concatenating. Note that in these illustrations, the trailing blanks from str1 are eliminated, while the leading blanks from str2 are not:

>> strcat(str1,str2)

ans =

xxx   yyy

>> length(ans)

ans =

9

>> strcat(str2,str1)

ans =

   yyyxxx

>> length(ans)

ans =

9

Posted Date: 10/20/2012 5:05:12 AM | Location : United States







Related Discussions:- Strcat function - concatenation, Assignment Help, Ask Question on Strcat function - concatenation, Get Answer, Expert's Help, Strcat function - concatenation Discussions

Write discussion on Strcat function - concatenation
Your posts are moderated
Related Questions
Functions to create special matrices: The MATLAB also has various functions which create special matrices. For illustration, the zeros function generates a matrix of all zeros

Find Minimum and Maximum for each row To find the maximum (or minimum) for each row, the dimension of 2 (that is how a MATLAB refers to rows) can be identified as the third arg

Types of User-defined Functions: We know how to write a user-defined function, stored in an M-file, which computes and returns one value. This is merely one type of the functi

Recursive Functions: The Recursion occurs whenever something is defined in terms of itself. In the programming, a recursive function is a function which calls itself. The Recu

Plot Functions: Faraway, we have plotted to generate two-dimensional plots and bar to generate bar charts. We have seen how to clear the Figure Window by using clf, and how to

Illustration of Labels and prompts: The program below prompts the user for endpoints (x1, y1) and (x2, y2) of a line segment, and computes the midpoint of the line segment, th

Polar Form: Any complex number z = a + bi can be thought of as a point (a,b) or vector in the complex plane in which the horizontal axis is the real part of z, and the vertica

Three-dimensional pie and bar: For the bar3 function, x & y vectors are passed and the function displays three-dimensional bars as shown in figure: Figure: Three-dimen

Built-in functions for Complex numbers:   We know that in MATLAB both i and j are built-in functions which return √-1 (therefore, they can be thought of as built-in constants).

Applications of Customized Strings: Labels, Prompts, Arguments to Functions: The one of very useful application of this is to involve numbers in strings that are used to plot