![photo](/responsive_image/150/150/0/0/0/cache/matlabcentral/profiles/13399353_1535561749245_DEF.jpg)
Rafi Ahmed
Followers: 0 Following: 0
I would love to explore different coding problems with the state-of-the-art approaches
Estadística
CLASIFICACIÓN
174.248
of 292.822
REPUTACIÓN
0
CONTRIBUCIONES
8 Preguntas
0 Respuestas
ACEPTACIÓN DE RESPUESTAS
25.0%
VOTOS RECIBIDOS
0
CLASIFICACIÓN
15.713 of 19.946
REPUTACIÓN
8
EVALUACIÓN MEDIA
5.00
CONTRIBUCIONES
2 Archivos
DESCARGAS
2
ALL TIME DESCARGAS
30
CLASIFICACIÓN
7.244
of 148.012
CONTRIBUCIONES
2 Problemas
71 Soluciones
PUNTUACIÓN
761
NÚMERO DE INSIGNIAS
3
CONTRIBUCIONES
0 Publicaciones
CONTRIBUCIONES
0 Público Canales
EVALUACIÓN MEDIA
CONTRIBUCIONES
0 Temas destacados
MEDIA DE ME GUSTA
Feeds
Resuelto
Find the longest sequence of 1's in a binary sequence.
Given a string such as s = '011110010000000100010111' find the length of the longest string of consecutive 1's. In this examp...
más de 3 años hace
Resuelto
Get the elements of diagonal and antidiagonal for any m-by-n matrix
In the problem <http://www.mathworks.com/matlabcentral/cody/problems/858-permute-diagonal-and-antidiagonal Problem 858. Permute ...
casi 5 años hace
Resuelto
Change a specific color in an image
The ability to change colors can be a useful tool in image processing. Given an m x n x 3 array (much like CData in images), fin...
alrededor de 5 años hace
Resuelto
random picture with random colours
write a function which creates a random(x,y) matrix with random RGB colours for example create_pic(5,5) gives us a 3d matrix. ...
alrededor de 5 años hace
Resuelto
Trimming Spaces
Given a string, remove all leading and trailing spaces (where space is defined as ASCII 32). Input a = ' singular value deco...
más de 5 años hace
Resuelto
Length of a short side
Calculate the length of the short side, a, of a right-angled triangle with hypotenuse of length c, and other short side of lengt...
más de 5 años hace
Resuelto
Duplicates
Write a function that accepts a cell array of strings and returns another cell array of strings *with only the duplicates* retai...
más de 5 años hace
Resuelto
Sort a list of complex numbers based on far they are from the origin.
Given a list of complex numbers z, return a list zSorted such that the numbers that are farthest from the origin (0+0i) appear f...
más de 5 años hace
Resuelto
Right and wrong
Given a vector of lengths [a b c], determines whether a triangle with those sides lengths is a right triangle: <http://en.wikipe...
más de 5 años hace
Resuelto
Convert a vector into a number
This is a sub problem related to this problem: <http://www.mathworks.com/matlabcentral/cody/problems/621-cryptomath-addition>...
más de 5 años hace
Resuelto
Summing digits
Given n, find the sum of the digits that make up 2^n. Example: Input n = 7 Output b = 11 since 2^7 = 128, and 1 + ...
más de 5 años hace
Resuelto
Love triangles
Given a vector of lengths [a b c], determines whether a triangle with non-zero area (in two-dimensional Euclidean space, smarty!...
más de 5 años hace
Resuelto
Rotate a Matrix
Input a Matrix x, Output y is the matrix rotating x 90 degrees clockwise
más de 5 años hace
Resuelto
Get the length of a given vector
Given a vector x, the output y should equal the length of x.
más de 5 años hace
Resuelto
Find the sum of the elements in the "second" diagonal
Find the sum of the elements in the diagonal that starts at the top-right corner and ends at the bottom-left corner.
más de 5 años hace
Resuelto
Make a Palindrome Number
Some numbers like 323 are palindromes. Other numbers like 124 are not. But look what happens when we add that number to a revers...
más de 5 años hace
Resuelto
Pattern matching
Given a matrix, m-by-n, find all the rows that have the same "increase, decrease, or stay same" pattern going across the columns...
más de 5 años hace
Problema
Scalar Matrix Manipulation
Assume, input x is a scalar matrix such as, x = 2 0 0 0 2 0 0 0 2 th...
más de 5 años hace | 1 | 46 solvers
Resuelto
Write a function man that takes a row vector v and returns a matrix H as follows..
Write a function called man that takes a row vector v as an input and returns a matrix H whose first column consist of the eleme...
más de 5 años hace
Resuelto
Given a 4x4 matrix, swap the two middle columns
If a = [1 2 3 4; 1 2 3 4; 1 2 3 4; 1 2 3 4]; then the result is ans = 1 3 2 4 1 3 2...
más de 5 años hace
Resuelto
Remove NaN ?
input -> matrix (n*m) with at least one element equal to NaN; output -> matrix(p*m), the same matrix where we deleted the enti...
más de 5 años hace
Resuelto
Check if number exists in vector
Return 1 if number _a_ exists in vector _b_ otherwise return 0. a = 3; b = [1,2,4]; Returns 0. a = 3; b = [1,...
más de 5 años hace
Resuelto
Area of an equilateral triangle
Calculate the area of an equilateral triangle of side x. <<http://upload.wikimedia.org/wikipedia/commons/e/e0/Equilateral-tr...
más de 5 años hace
Resuelto
Swap the input arguments
Write a two-input, two-output function that swaps its two input arguments. For example: [q,r] = swap(5,10) returns q = ...
más de 5 años hace
Resuelto
Pentagonal Numbers
Your function will receive a lower and upper bound. It should return all pentagonal numbers within that inclusive range in ascen...
más de 5 años hace
Resuelto
Replicate elements in vectors
Replicate each element of a row vector (with NaN) a constant number of times. Examples n=2, A=[1 2 3] -> [1 1 2 2 3 3] ...
más de 5 años hace
Resuelto
Back to basics 21 - Matrix replicating
Covering some basic topics I haven't seen elsewhere on Cody. Given an input matrix, generate an output matrix that consists o...
más de 5 años hace
Resuelto
Find the largest value in the 3D matrix
Given a 3D matrix A, find the largest value. Example >> A = 1:9; >> A = reshape(A,[3 1 3]); >> islargest(A) a...
más de 5 años hace
Resuelto
Most nonzero elements in row
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...
más de 5 años hace
Resuelto
Making change
Given an amount of currency, return a vector of this form: [100 50 20 10 5 2 1 0.5 0.25 0.1 0.05 0.01] Example: Input a = ...
más de 5 años hace