Gelöst


Make one big string out of two smaller strings
If you have two small strings, like 'a' and 'b', return them put together like 'ab'. 'a' and 'b' => 'ab' For extra ...

etwa 8 Jahre vor

Frage


Strfind to contain complex pattern
I have created the following program to search for sentences. I want to include those that only begin with vowels. a = 'Jo...

etwa 8 Jahre vor | 1 Antwort | 0

1

Antwort

Gelöst


Remove any row in which a NaN appears
Given the matrix A, return B in which all the rows that have one or more <http://www.mathworks.com/help/techdoc/ref/nan.html NaN...

etwa 8 Jahre vor

Gelöst


Remove the vowels
Remove all the vowels in the given phrase. Example: Input s1 = 'Jack and Jill went up the hill' Output s2 is 'Jck nd Jll wn...

etwa 8 Jahre vor

Frage


Problem with reading text file and making changes
I have a file in a txt format with the following data 0 584547.75 4052042.76 1 584543.25 4052030.13 2 584542.06 40520...

etwa 8 Jahre vor | 2 Antworten | 0

2

Antworten

Frage


What is wrong with the code?
I want to remove the vowels and I am doing something wrong. chr = 'The fast black dog' for i = 1:length(chr) if c...

etwa 8 Jahre vor | 1 Antwort | 0

1

Antwort

Gelöst


Rotate a Matrix by 90 degrees
Rotate a Matrix by 90 degrees Example: If the input is: X = 1 2 3 4 5 6 7 8 9 ...

etwa 8 Jahre vor

Beantwortet
Problem with reading text file and making changes
I have found the answer: M = dlmread('C:\Users\G\Desktop\topo.txt',' '); %replace path as appropriate M(:,1) = [] dl...

etwa 8 Jahre vor | 0

| akzeptiert

Gelöst


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

etwa 8 Jahre vor

Gelöst


Celsius to Kelvin
Convert Celsius degrees to Kelvin temperature.

etwa 8 Jahre vor

Gelöst


row removal
Remove the nth row from input matrix M and return the resulting matrix in output N.

etwa 8 Jahre vor

Frage


What is wrong with code?
I want a matrix as follows: n = 12 b = zeros(n,n) b(1,:) = 1:n b(2,:) = 1:n.^2 etc... How can I express th...

etwa 8 Jahre vor | 1 Antwort | 0

1

Antwort

Gelöst


radius of a spherical planet
You just measured its surface area, that is the input.

etwa 8 Jahre vor

Gelöst


Too mean-spirited
Find the mean of each consecutive pair of numbers in the input row vector. For example, x=[1 2 3] ----> y = [1.5 2.5] x=[1...

etwa 8 Jahre vor

Gelöst


Find the last digit
FInd the last digit of a given number. Given number is the input and output should be the last digit of that number.

etwa 8 Jahre vor

Gelöst


Divide by 4
Given the variable x as your input, divide it by four and put the result in y.

etwa 8 Jahre vor

Gelöst


only input
Return the output without writing any code into the function.

etwa 8 Jahre vor

Gelöst


Reverse the Words (not letters) of a String
*Description* Change the words of a string such that the words appear in reverse order. You may assume that the string is a n...

etwa 8 Jahre vor

Gelöst


Beginner's Problem - Squaring
Try out this test problem first. Given the variable x as your input, square it by two and put the result in y. Examples: ...

etwa 8 Jahre vor

Gelöst


How to find the position of an element in a vector without using the find function
Write a function posX=findPosition(x,y) where x is a vector and y is the number that you are searching for. Examples: fin...

etwa 8 Jahre vor

Gelöst


Add two numbers
Calculate the sum of two numbers. Example input = [2 3] output = 5

etwa 8 Jahre vor

Gelöst


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

etwa 8 Jahre vor

Gelöst


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

etwa 8 Jahre vor

Gelöst


Set the array elements whose value is 13 to 0
Input A either an array or a vector (which can be empty) Output B will be the same size as A . All elements of A equal to 13...

etwa 8 Jahre vor

Gelöst


Summing digits
Given n, find the sum of the digits that make up 2^n. Example: Input n = 7 Output b = 11 since 2^7 = 128, and 1 + ...

etwa 8 Jahre vor

Gelöst


Tell me the slope
Tell me the slope, given a vector with horizontal run first and vertical rise next. Example input: x = [10 2];

etwa 8 Jahre vor

Frage


How to sum the digits of a string?
I have created the following program to sum the digits of a number, that derives from the following expression: op = 2^n, where ...

etwa 8 Jahre vor | 1 Antwort | 1

1

Antwort

Gelöst


Matrix of almost all zeros, except for main diagonal
Write a program to input an integer n and build a n-by-n matrix with the numbers 1,2,...,n on the main diagonal and zeros elsewh...

etwa 8 Jahre vor

Gelöst


Change matrix to vector
Vector is a matrix whose size is 1 x n or n x 1. Change matrix to vector. x = 4 3 5 1 ...

etwa 8 Jahre vor

Gelöst


Convert radians to degrees
Given input in radians, output to degrees

etwa 8 Jahre vor

Mehr laden