Vector with a repeated entry
Create a row vector of length n, filled with 4's. For example, if n = 3,
output = [4 4 4]
Hint:
Search for the function...
8年弱 前
解決済み
Area of a circle
Given the radius x, y would be the area of a circle.
Pi = 3.1416
8年弱 前
解決済み
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; ...
Who knows the last digit of pi?
There is only one man who knows the last digit of pi, who is that man?
Give the name of that man, who, by popular believe, can ...
Rotate and display numbered tile
Imagine a square tile with four numbers on it, one on each edge. We will call these edges north, east, south, and west.
If th...
Stuff the Board
You have a stack of tiles to put onto an array-like playing board. Each tile has a number (always an integer), and the board var...
8年弱 前
解決済み
Scoring for oriented dominoes
Given a list of ordered pairs, and the order they should be placed in a line, find the sum of the absolute values of the differe...