Community Profile

photo

Divyam Tiwari


Last seen: 16 dagen ago
112 total contributions since 2021

Divyam Tiwari's Badges

  • CUP Challenge Master
  • Introduction to MATLAB Master
  • Community Group Solver
  • Solver

View details...

Contributions in
View by

Solved


Find the next Fibonacci number
In the sequence of Fibonacci numbers, every number is the sum of the two preceding ones: 1, 1, 2, 3, 5, 8, 13, 21, 34, 55...

15 dagen ago

Solved


Return the Fibonacci Sequence
Write a code which returns the Fibonacci Sequence such that the largest value in the sequence is less than the input integer N. ...

15 dagen ago

Solved


Fibonacci sequence
Calculate the nth Fibonacci number. Given n, return f where f = fib(n) and f(1) = 1, f(2) = 1, f(3) = 2, ... Examples: Inpu...

16 dagen ago

Solved


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

16 dagen ago

Solved


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

16 dagen ago

Solved


Is my wife right?
Regardless of input, output the string 'yes'.

16 dagen ago

Solved


Pizza!
Given a circular pizza with radius _z_ and thickness _a_, return the pizza's volume. [ _z_ is first input argument.] Non-scor...

16 dagen ago

Solved


Determine if input is odd
Given the input n, return true if n is odd or false if n is even.

16 dagen ago

Solved


Given a matrix, swap the 2nd & 3rd 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...

16 dagen ago

Solved


matrix zigzag
Unfold a 2-D matrix to a 1-D array in zig-zag order, e.g., for matrix [ 1 2 3 ; 4 5 6 ; 7 8 9 ] the resulting 1-...

16 dagen ago

Solved


Multiples of a Number in a Given Range
Given an integer factor _f_ and a range defined by _xlow_ and _xhigh_ inclusive, return a vector of the multiples of _f_ that fa...

24 dagen ago

Solved


Project Euler: Problem 3, Largest prime factor
The prime factors of 13195 are 5, 7, 13 and 29. What is the largest prime factor of the number being input, input might be ui...

24 dagen ago

Solved


Smith numbers
Return true if the input is a Smith number in base ten. Otherwise, return false. Read about Smith numbers at <http://en.wikipedi...

24 dagen ago

Solved


Prime factor digits
Consider the following number system. Calculate the prime factorization for each number n, then represent the prime factors in a...

24 dagen ago

Solved


Calculate the Number of Sign Changes in a Row Vector (No Element Is Zero)
For a row vector: V=[7 1 2 -3] there is one sign change (from 2 to -3). So, the function you write must return N=1. F...

28 dagen ago

Solved


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

28 dagen ago

Solved


Create an n-by-n null matrix and fill with ones certain positions
The positions will be indicated by a z-by-2 matrix. Each row in this z-by-2 matrix will have the row and column in which a 1 has...

28 dagen ago

Solved


Draw a '4' in a zero matrix!

28 dagen ago

Solved


Draw a '6' in a zero matrix!

28 dagen ago

Solved


Draw a '9' in a zero matrix!

28 dagen ago

Solved


Draw a '7' in a zero matrix!

28 dagen ago

Solved


Draw a '8' in a zero matrix!

28 dagen ago

Solved


Draw a '3' in a zero matrix!

28 dagen ago

Solved


Draw a '2' in a zero matrix!

28 dagen ago

Solved


Draw a '5' in a zero matrix!

28 dagen ago

Solved


Draw a '1' in a zero matrix!

30 dagen ago

Solved


Is A the inverse of B?
Given a matrix A and a matrix B, is A the inverse of B? >>A=[2,4;3,5]; >>B=[-2.5,2;1.5,-1]; >>isInverse...

30 dagen ago

Solved


Rotate Matrix @180 degree
Rotate Matrix @180 degree Example A=[8 1 6; 3 5 7; 4 9 2], then answer would be [2 9 4;...

30 dagen ago

Solved


Converts numbers into characters
Converts numbers into characters

30 dagen ago

Load more