Solved


Sums of Multiple Pairs of Triangular Numbers
This is a follow-up to <https://www.mathworks.com/matlabcentral/cody/problems/44289 Problem 44289> - Find two triangular numbers...

6 years ago

Solved


A Simple Tide Gauge with MATLAB
*&#8767 &#8767 &#8767 &#8767 &#8767 &#8767 &#8767 &#8767* You are standing in a few inches of sea water on a beach. You a...

6 years ago

Solved


sum of non-primes
The sum of the non-primes no larger than 10 is 1+4+6+8+9+10=38 Find the sum of all the positive non-prime integers that do no...

6 years ago

Solved


Find two triangular numbers whose sum is input.
Find two triangular numbers whose sum is _input_. Note: The difference beetween the triangular numbers should be minimum.

6 years ago

Solved


Divisors of an integer
Given a number N, return a vector V of all integers that divide N. For example, N = 10 Then V=[1 2 5 10]

6 years ago

Solved


Count up then down
Create a function that produces counting up from 0 up to n then down to 0 n=2 --> 0 1 2 1 0 n=3 --> ...

6 years ago

Solved


Finding perimeter of a rectangle
A rectangle has a length of x centimeters and a width of w centimeters. Find the perimeter.

6 years ago

Solved


Matlab Basics - Rounding I
Write a script to round x DOWN to the next lowest integer: e.g. x = 2.3 --> x = 2 also: x = 2.7 --> x = 2

6 years ago

Solved


Number of digits in an integer
Specifies how many digits in a given integer. Example: in=100 ==> out=3

6 years ago

Solved


select the primes of a vector
Find the prime numbers in a vector

6 years ago

Solved


Vectorize the digits of an Integer
Create a vector of length N for an integer of N digits. x = 123045; x_vec = [1 2 3 0 4 5]; I happened upon a trick ...

6 years ago

Solved


Solving Quadratic Equations (Version 1)
Quadratic equations have the form: ax^2 + bx + c = 0. Example: x^2 + 3x + 2 = 0, where a = 1, b = 3, and c = 2. The equation has...

6 years ago

Solved


Coin change combinations.
Using only pennies (1), nickels (5), dimes (10), quarters (25), half dollars (50), and dollars (100), how many different combina...

6 years ago

Solved


Probability of red tulips (at both ends of a row)
I planted tulip bulbs in a row on my flower bed. I thought that I had planted white tulips all. However, later, it turned out t...

6 years ago

Solved


Throwing Dice - Will You Be Eaten By The Dragon?
You and a dragon have agreed to let dice rolls determine whether it eats you or not. The dragon will roll a single die, of x ...

6 years ago

Solved


Unique dice configurations
Given a number of dice N and the number of sides on each die S, write a MATLAB function that will output how many unique permuta...

6 years ago

Solved


Eliminate Outliers Using Interquartile Range
Given a vector with your "data" find the outliers and remove them. To determine whether data contains an outlier: # Identi...

6 years ago

Solved


Probability of Choosing a Red Ball
Given two jars of red and blue balls, find the probability of choosing a red ball from Jar 1 after going through the steps. ...

6 years ago

Solved


Chess probability
The difference in the ratings between two players serves as a predictor of the outcome of a match (the <http://en.wikipedia.org/...

6 years ago

Solved


Coin Tossing: Probability of Same Heads for N tosses
A pair of physicists toss a coin n times each. What is the probability that they tossed the same number of heads? *Input:*...

6 years ago

Solved


The almost-birthday problem.
This is a harder version of the birthday problem. Now, you will have to determine the probability that two or more people in a r...

6 years ago

Solved


Calculate the probability that at least two people in a group share the same birthday.
Calculate the probability that at least two people in a group share the same birthday. Given an integer input n, return to 0.015...

6 years ago

Solved


Don't be mean. Be nice!
For this problem, you will be given a range of single digits R, and a separate number K. You job is to calculate the mean of al...

6 years ago

Solved


Given n, create n random numbers such that their standard deviation is also n.
Given n, create n random numbers such that their standard deviation is also n.

6 years ago

Solved


The Birthday Phenomenon
First off, leap years are not being considered for this. In fact the year that people are born shouldn't be taken into considera...

6 years ago

Solved


Square the input
Given a scalar or vector x, return the square of each element. Example x = [7 2] answer = [49 4]

6 years ago

Solved


The glass half full
Identical glasses are placed in a triangular tower structure, such that the top level (L = 1) comprises one glass, the next leve...

6 years ago

Solved


Predicting life and death of a memory-less light bulb
*&#128161 &#128161 &#128161 &#128161 &#128161 &#128161 &#128161 &#128161 &#128161 &#128161 &#128161 &#128161 &#128161 &#128161 &...

6 years ago

Solved


Spot the First Occurrence of 5
This problem series invites you to solve two simple problems related to the integer NUMBER FIVE, in order to celebrate <https://...

6 years ago

Solved


Basic electricity in a dry situation
&#9889 &#9889 &#9889 &#9889 &#9889 &#9889 &#9889 &#9889 &#9889 &#9889 &#9889 &#9889 &#9889 &#9889 &#9889 &#9889 &#9889 &#9889 &#...

6 years ago

Load more