Sum of the Multiplication of Vectors
Given the vectors x and y as input, multiply the vectors and return the summation of its elements.
Example:
x = [1 2 ...
約9年 前
解決済み
Matlab Basics II - squares
Write a function that takes matrix A, and squares each element in the matrix
example:
A = [1 2 3]
output = [1 4 9]
2倍してみよう - ここからスタート!
初めにこの問題を試してみよう。
入力としてxを与え、それを2倍して結果をyに代入せよ。
Examples:
Input x = 2
Output y is 4
Input x = 17
Output y is 34
...
約9年 前
解決済み
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:/...
MATCH THE STRINGS (2 CHAR) very easy
Match the given string based on first two characters on each string.
For example
A='harsa';
b='harish'; result '1'
...
06 - Matrix Equations 2
Define the vectors _aVec_ and _bVec_:
<<http://samle.dk/STTBDP/Assignment1_2a.png>>
and
<<http://samle.dk/STTBDP/Assig...
約9年 前
解決済み
Create a vector
Create a vector from 0 to n by intervals of 2.
約9年 前
解決済み
Hydrostatic Pressure
Given depth(height), in m, find the pressure under a body of water. Need to know the density of water(kg/m^3), and gravity(m/s^2...
約9年 前
解決済み
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...
約9年 前
解決済み
frame of the matrix
Given the matrix M, return M without the external frame.
約9年 前
解決済み
Swap two numbers
Example
Input:
a = 10
b = 20
Output
a = 20
b = 10