Professional Interests: Automotive
Top 5% contributor
I am using S function builder and I am getting the error :: compiler error in _kids--Bad rule number 0 for lcc compiler.
Asked 3 years ago
When I am building the SFunction I am building with Microsoft Visual C++ 6.0 I am getting
S function builder LINK : fatal erro...
Program an exclusive or operation *without* using the MATLAB function xor.
Use logical operators like |, &, ~, ... instead.
3 years ago
Some numbers like 323 are palindromes. Other numbers like 124 are not. But look what happens when we add that number to a revers...
Write a two-input, two-output function that swaps its two input arguments. For example:
[q,r] = swap(5,10)
returns q = ...
If you have two small strings, like 'a' and 'b', return them put together like 'ab'.
'a' and 'b' => 'ab'
For extra ...
Given the number x, y must be the summation of all integers from 1 to 2^x.
For instance if x=2 then y must be 1+2+3+4=10.
Write a function posX=findPosition(x,y) where x is a vector and y is the number that you are searching for.
Remove all the vowels in the given phrase.
Input s1 = 'Jack and Jill went up the hill'
Output s2 is 'Jck nd Jll wn...
Are all the letters in the input string capital letters?
'MNOP' -> 1
'MN0P' -> 0
Given a vector of numbers, return true if one of the numbers is a square of one of the other numbers. Otherwise return false.
you just discovered its circumference, that is the input.
Given the matrix a, return the index r of the row with the most nonzero elements. Assume there will always be exactly one row th...
Given a circular pizza with radius _z_ and thickness _a_, return the pizza's volume. [ _z_ is first input argument.]
If we list all the natural numbers below 10 that are multiples of 3 or 5, we get 3, 5, 6 and 9. The sum of these multiples is 23...
Given two lists of numbers, determine the weighted average.
[1 2 3] and [10 15 20]
should result in
Calculate the nth Fibonacci number.
Given n, return f where f = fib(n) and f(1) = 1, f(2) = 1, f(3) = 2, ...
Given an integer n, make an n-by-n matrix made up of alternating ones and zeros as shown below. The a(1,1) should be 1.
Given n, find the sum of the digits that make up 2^n.
Input n = 7
Output b = 11
since 2^7 = 128, and 1 + ...
Find the mean of each consecutive pair of numbers in the input row vector. For example,
x=[1 2 3] ----> y = [1.5 2.5]
Again, as in "Is my wife right?" ( <http://www.mathworks.com/matlabcentral/cody/problems/149-is-my-wife-right> ), answer 'yes' r...
Return true if the elements of the input vector increase monotonically (i.e. each element is larger than the previous). Return f...
Reverse the vector elements.
Input x = [1,2,3,4,5,6,7,8,9]
Output y = [9,8,7,6,5,4,3,2,1]
Flip the outermost columns of matrix A, so that the first column becomes the last and the last column becomes the first. All oth...
Given an input vector x, find all elements of x less than 0 or greater than 10 and replace them with NaN.
Remove the nth column from input matrix A and return the resulting matrix in output B.
A = [1 2 3; 4 5 6];
At one time or another, we all had to memorize boring times tables. 5 times 5 is 25. 5 times 6 is 30. 12 times 12 is way more th...
Write a function which returns every other element of the vector passed in. That is, it returns the all odd-numbered elements, s...
Regardless of input, output the string 'yes'.
Find the sum of all the numbers of the input vector x.
Input x = [1 2 3 5]
Output y is 11
Input x ...