Community Profile

photo

Debasish Samal


2019년부터 활동

통계

All
  • Knowledgeable Level 2
  • First Answer
  • Community Group Solver
  • Introduction to MATLAB Master
  • Solver

배지 보기

Content Feed

보기 기준

문제를 풀었습니다


Replace NaNs with the number that appears to its left in the row.
Replace NaNs with the number that appears to its left in the row. If there are more than one consecutive NaNs, they should all ...

거의 5년 전

문제를 풀었습니다


Which doors are open?
There are n doors in an alley. Initially they are all shut. You have been tasked to go down the alley n times, and open/shut the...

거의 5년 전

문제를 풀었습니다


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...

거의 5년 전

문제를 풀었습니다


Find the numeric mean of the prime numbers in a matrix.
There will always be at least one prime in the matrix. Example: Input in = [ 8 3 5 9 ] Output out is 4...

거의 5년 전

문제를 풀었습니다


Subset Sum
Given a vector v of integers and an integer n, return the the indices of v (as a row vector in ascending order) that sum to n. I...

거의 5년 전

답변 있음
How to find position of array
You can use regular expressions to do this. x = '11111100001111'; expr = '1*'; [sInd,eInd] = regexp(x, expr) This gives the ...

거의 5년 전 | 1

| 수락됨

답변 있음
Given a matrix A, create the matrix B whose elements are the neighbor sumr for A
There are multiple indexing errors in your code Jose. Here is the rectified version. A = [1 2 3 4; 5 6 7 8; 9 10 11 12; 13 14 1...

거의 5년 전 | 1

| 수락됨

문제를 풀었습니다


Trimming Spaces
Given a string, remove all leading and trailing spaces (where space is defined as ASCII 32). Input a = ' singular value deco...

거의 5년 전

문제를 풀었습니다


Find the two-word state names
Given a list of states, remove all the states that have two-word names. If s1 = 'Alabama Montana North Carolina Vermont N...

거의 5년 전

문제를 풀었습니다


Return a list sorted by number of occurrences
Given a vector x, return a vector y of the unique values in x sorted by the number of occurrences in x. Ties are resolved by a ...

거의 5년 전

문제를 풀었습니다


Renaming a field in a structure array
MATLAB has a <http://www.mathworks.com/help/techdoc/ref/setfield.html setfield> and a <http://www.mathworks.com/help/techdoc/ref...

거의 5년 전

문제를 풀었습니다


Cell joiner
You are given a cell array of strings and a string delimiter. You need to produce one string which is composed of each string fr...

거의 5년 전

문제를 풀었습니다


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 + ...

거의 5년 전

문제를 풀었습니다


Bullseye Matrix
Given n (always odd), return output a that has concentric rings of the numbers 1 through (n+1)/2 around the center point. Exampl...

거의 5년 전

답변 있음
Regular expressions: number that does not begin or end with a letter
Here is a solution to your answer. This solution separates all the decimal numbers/integers from the non integers/decimals. str...

거의 5년 전 | 0

| 수락됨

답변 있음
variant sink declaring variables
One thing you can try here is using 2 switches. Set the threshold value in both switches and supply the inputs accordingly. For...

거의 5년 전 | 0

문제를 풀었습니다


Make a checkerboard matrix
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. Examp...

거의 5년 전

문제를 풀었습니다


Pascal's Triangle
Given an integer n >= 0, generate the length n+1 row vector representing the n-th row of <http://en.wikipedia.org/wiki/Pascals_t...

거의 5년 전

문제를 풀었습니다


Find the alphabetic word product
If the input string s is a word like 'hello', then the output word product p is a number based on the correspondence a=1, b=2, ....

거의 5년 전

문제를 풀었습니다


Find all elements less than 0 or greater than 10 and replace them with NaN
Given an input vector x, find all elements of x less than 0 or greater than 10 and replace them with NaN. Example: Input ...

거의 5년 전

문제를 풀었습니다


Binary numbers
Given a positive, scalar integer n, create a (2^n)-by-n double-precision matrix containing the binary numbers from 0 through 2^n...

거의 5년 전

문제를 풀었습니다


Which values occur exactly three times?
Return a list of all values (sorted smallest to largest) that appear exactly three times in the input vector x. So if x = [1 2...

거의 5년 전

문제를 풀었습니다


Quote Doubler
Given a string s1, find all occurrences of the single quote character and replace them with two occurrences of the single quote ...

거의 5년 전

문제를 풀었습니다


Indexed Probability Table
This question was inspired by a Stack Overflow question forwarded to me by Matt Simoneau. Given a vector x, make an indexed pro...

거의 5년 전

문제를 풀었습니다


Find state names that start with the letter N
Given a list of US states, remove all the states that start with the letter N. If s1 = 'Alabama Montana Nebraska Vermont Ne...

거의 5년 전

문제를 풀었습니다


QWERTY coordinates
Given a lowercase letter or a digit as input, return the row where that letter appears on a <http://en.wikipedia.org/wiki/Keyboa...

거의 5년 전

답변 있음
Euler's Method
There is a parentheses mismatch in your code for the euler's method. Replace that line with: y(i+1) = y(i) + h *(sin(x) * ( 1 ...

거의 5년 전 | 0

| 수락됨

문제를 풀었습니다


Remove any row in which a NaN appears
Given the matrix A, return B in which all the rows that have one or more <http://www.mathworks.com/help/techdoc/ref/nan.html NaN...

거의 5년 전

문제를 풀었습니다


Find the peak 3n+1 sequence value
A Collatz sequence is the sequence where, for a given number n, the next number in the sequence is either n/2 if the number is e...

거의 5년 전

답변 있음
Import data with column separated with a comma, and comma as decimal place symbol
One thing that you can do here is import the data and save it in a variable say 'var'. Then replace the commas by a decimal poin...

거의 5년 전 | 0

더 보기