
Andrew Brindley
Followers: 0 Following: 0
Statistics
0 Problems
277 Solutions
RANK
N/A
of 297.891
REPUTATION
N/A
CONTRIBUTIONS
0 Questions
0 Answers
ANSWER ACCEPTANCE
0.00%
VOTES RECEIVED
0
RANK
of 20.503
REPUTATION
N/A
AVERAGE RATING
0.00
CONTRIBUTIONS
0 Files
DOWNLOADS
0
ALL TIME DOWNLOADS
0
CONTRIBUTIONS
0 Posts
CONTRIBUTIONS
0 Public Channels
AVERAGE RATING
CONTRIBUTIONS
0 Highlights
AVERAGE NO. OF LIKES
Feeds
Solved
Find the nearest prime number
Happy 5th birthday, Cody! Since 5 is a prime number, let's have some fun looking for other prime numbers. Given a positive in...
bijna 3 jaar ago
Solved
Rotate a Matrix
Input a Matrix x, Output y is the matrix rotating x 90 degrees clockwise
bijna 3 jaar 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...
bijna 3 jaar ago
Solved
Sum of first n positive integers
Given n, find the sum of first n positive integers Example: If n=10, then x=1,2,3,4,5,6,7,8,9,10. The sum of these terms is 55
bijna 3 jaar ago
Solved
02 - Vector Variables 1
Make the following variable: <<http://samle.dk/STTBDP/Assignment1_2a.png>>
bijna 3 jaar ago
Solved
Union of two set decreasing order
Union of two set decreasing order Say, x=[1 2 5] and y=[5 7 8] then answer must be [8 7 5 2 1]
ongeveer 3 jaar ago
Solved
Case-insensitive Character Detection
Find the index of a particular character in a string ignoring case. Example Input: x = 'aAbhhfdf' n = 'a' ...
ongeveer 3 jaar ago
Solved
Determine the mean of matrix
Determine the mean of matrix without using mean function Hint: use simple algorithm
ongeveer 3 jaar ago
Solved
Find out total non zero element of matrix
Find out Non zero element of matrix A=magic(5) 17 24 1 8 15 23 5 7 14 16 4 6...
ongeveer 3 jaar ago
Solved
Find out magnitude of vector
Find out magnitude of vector. Say x=[1 2 3], then answer must sqrt(1^2+2^2+3^2) Please don't use sum function. If you l...
ongeveer 3 jaar ago
Solved
Find out sum of prime number till given number
Find out sum of prime number till given number Example, if number is 10, then answer must be 17.
ongeveer 3 jaar ago
Solved
Create an index-powered vector
Given a input vector x, return y as index-powered vector as shown below. Example x = [2 3 6 9] then y should be [...
ongeveer 3 jaar 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...
ongeveer 3 jaar 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...
ongeveer 3 jaar ago
Solved
Square the input
Given a scalar or vector x, return the square of each element. Example x = [7 2] answer = [49 4]
ongeveer 3 jaar 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...
ongeveer 3 jaar ago
Solved
Back to basics 8 - Matrix Diagonals
Covering some basic topics I haven't seen elsewhere on Cody. Given an input vector of numbers, output a square array with the...
ongeveer 3 jaar ago
Solved
Sum the squares of numbers from 1 to n
For a given value of n return the sum of square of numbers from 1 to n. Example For n = 2 then sum of squares = 5 (1^2 + ...
ongeveer 3 jaar ago
Solved
Increment a number, given its digits
Take as input an array of digits (e.g. x = [1 2 3]) and output an array of digits that is that number "incremented" properly, (i...
ongeveer 3 jaar ago
Solved
Insert zeros into vector
Insert zeros after each elements in the vector. Number of zeros is specified as the input parameter. For example: x = [1 ...
ongeveer 3 jaar ago
Solved
Find the largest number
Find the largest number |x| among 4 numbers given as variables |a|, |b|, |c|, and |d|. Example: Input: a = 4; b = 7; c ...
ongeveer 3 jaar ago
Solved
Sum of Two Numbers
Given two integer numbers x and y, calculate their sum and put it in z. Examples: Inputs x = 2, y = 4 Output z is 6 ...
ongeveer 3 jaar ago
Solved
Prime numbers between a , b.
Find all prime number between a & b (including a and b). example: a=100 b=120 y= [101 103 107 109 113]
ongeveer 3 jaar ago
Solved
Make a run-length companion vector
Given a vector x, return a vector r that indicates the run length of any value in x. Each element in r shows how many times the ...
ongeveer 3 jaar ago
Solved
Binary code (array)
Write a function which calculates the binary code of a number 'n' and gives the result as an array(vector). Example: Inpu...
ongeveer 3 jaar ago
Solved
Element by element multiplication of two vectors
Given two input vectors, return the element-by-element product. Example A = [1 2 3] B = [7 3 1] The answer should be...
ongeveer 3 jaar ago