Community Profile

photo

Luffy


IIT ROORKEE

2012년부터 활동

I hated programming until I met MATLAB.
Professional Interests: VLSI

통계

All
  • Knowledgeable Level 3
  • Thankful Level 3
  • Revival Level 1
  • Knowledgeable Level 2
  • First Answer
  • Solver

배지 보기

Content Feed

보기 기준

문제를 풀었습니다


Return the 3n+1 sequence for n
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...

8년 초과 전

문제를 풀었습니다


Add two to x
Create a script such that y equals x plus 2

8년 초과 전

문제를 풀었습니다


Symmetry of vector
Determine whether the vector is symmetric or not (vector could be even or odd in length). For example: x = [1 2 3 3 2 1] ...

거의 11년 전

문제를 풀었습니다


Mode
Find the mode of the vector Assumption: no vector is bimodal Example 1: input=[1 2 3 4 4]; output=4 Example 2: input=[7...

거의 11년 전

문제를 풀었습니다


Try 1.5.4: Celsius to Fahrenheit
Write a program to convert an input given in Celsius to Fahrenheit. Examples: Input celsiusValue = 100 Output fahrValu...

거의 11년 전

문제를 풀었습니다


only input
Return the output without writing any code into the function.

거의 11년 전

문제를 풀었습니다


Create matrix of replicated elements
Given an input element x, and the dimensions, (m, n) return a matrix of size m x n filled with element x. Example: Input: ...

거의 11년 전

문제를 풀었습니다


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

거의 11년 전

문제를 풀었습니다


Distance walked 1D
Suppose you go from position 7 to 10 to 6 to 4. Then you have walked 9 units of distance, since 7 to 10 is 3 units, 10 to 6 is 4...

거의 11년 전

문제를 풀었습니다


Geometric series
Find the sum, given the first term t1, the common ratio r, and number of terms n. Examples If input t1=1, r=1, n=7 the...

11년 초과 전

문제를 풀었습니다


Arrange vector in ascending order
Arrange a given vector in ascending order. input = [4 5 1 2 9]; output = [1 2 4 5 9];

11년 초과 전

문제를 풀었습니다


Make a random, non-repeating vector.
This is a basic MATLAB operation. It is for instructional purposes. --- If you want to get a random permutation of integer...

11년 초과 전

문제를 풀었습니다


Rotate a Matrix
Input a Matrix x, Output y is the matrix rotating x 90 degrees clockwise

11년 초과 전

문제를 풀었습니다


Whether the input is vector?
Given the input x, return 1 if x is vector or else 0.

11년 초과 전

문제를 풀었습니다


Find the largest value in the 3D matrix
Given a 3D matrix, A, find the largest value. E.g. >> A = 1:9; >> A=reshape(A,[3 1 3]); >> islargest(A) ans = 9

11년 초과 전

문제를 풀었습니다


Multiply a column by a row
* Given a column vector C and and a row vector R. * Output a matrix M. * Every column of M equals to C multiplied by correspon...

11년 초과 전

문제를 풀었습니다


Get the length of a given vector
Given a vector x, the output y should equal the length of x.

11년 초과 전

문제를 풀었습니다


Compute a dot product of two vectors x and y
x and y are input vectors, d is a number and contains their dot product

11년 초과 전

문제를 풀었습니다


First N Perfect Squares
*Description* Return the first N perfect squares *Example* input = 4; output = [ 1 4 9 16 ];

11년 초과 전

문제를 풀었습니다


Back to basics 1 - Saving
Covering some basic topics I haven't seen elsewhere on Cody. Given an input variable 'x', save it to disk in a file named 'co...

11년 초과 전

문제를 풀었습니다


Back to basics 23 - Triangular matrix
Covering some basic topics I haven't seen elsewhere on Cody. Given an input matrix, return a matrix with all elements above a...

11년 초과 전

문제를 풀었습니다


Project Euler: Problem 10, Sum of Primes
The sum of the primes below 10 is 2 + 3 + 5 + 7 = 17. Find the sum of all the primes below the input, N. Thank you <http:/...

11년 초과 전

문제를 풀었습니다


Back to basics 22 - Rotate a matrix
Covering some basic topics I haven't seen elsewhere on Cody. Rotate the input matrix 90 degrees counterclockwise (e.g. [1 2; ...

11년 초과 전

문제를 풀었습니다


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.

11년 초과 전

문제를 풀었습니다


Omit columns averages from a matrix
Omit columns averages from a matrix. For example: A = 16 2 3 13 5 11 10 8 9 7 ...

11년 초과 전

문제를 풀었습니다


Arrange Vector in descending order
If x=[0,3,4,2,1] then y=[4,3,2,1,0]

11년 초과 전

문제를 풀었습니다


Check if sorted
Check if sorted. Example: Input x = [1 2 0] Output y is 0

11년 초과 전

문제를 풀었습니다


Sorted highest to lowest?
Return 1 if the input is sorted from highest to lowest, 0 if not. Example: 1:7 -> 0 [7 5 2] -> 1

11년 초과 전

문제를 풀었습니다


Column Removal
Remove the nth column from input matrix A and return the resulting matrix in output B. So if A = [1 2 3; 4 5 6]; and ...

11년 초과 전

문제를 풀었습니다


Reverse the vector
Reverse the vector elements. Example: Input x = [1,2,3,4,5,6,7,8,9] Output y = [9,8,7,6,5,4,3,2,1]

11년 초과 전

더 보기