A résolu


Número Repetido
Dado um número inteiro N, verifique se o número é composto apenas do mesmo inteiro VerificaRepetido(123) = false; VerificaRepe...

presque 4 ans il y a

A résolu


Fizz
Dado um número inteiro n, retorne 'fizz' se esse valor for multiplo de 3, ou retorne o valor caso contrario. Fizz(3) = 'fizz'; ...

presque 4 ans il y a

A résolu


Matrizes Multiplicaveis
Dadas duas matrizes M1 e M2, verifique se as matrizes podem ser multiplicadas uma pela outra M1 = [1 2 3; 4 5 6] M2 = [7; 8; 9...

presque 4 ans il y a

A résolu


Maior Primo
Dado um valor inteiro N, qual o maior valor primo <= N MaiorPrimo(5) = 5; MaiorPrimo(10) = 7;

presque 4 ans il y a

A résolu


Tabuada
Dado um inteiro N, retorne um vetor contendo a tabuada de N de 1 a 10; ex: Tabuada(5) = [5, 10, 15, 20, 25, 30, 35, 40, 45, 50...

presque 4 ans il y a

A résolu


Tipos de Triangulos
Dados os tamanhos dos lados de um triangulos A, B e C. Retorne qual o tipo do triangulo: 'equilátero', 'escaleno' ou 'isósceles'...

presque 4 ans il y a

A résolu


Letras Maisculas
Dado uma string A, retorne apenas os caracteres maiúsculos de A Maiusculas('Hello World') = 'HW';

presque 4 ans il y a

A résolu


Triangulo Semelhante
Dados dois vetores A = (a1, a2, a3) e B = (b1, b2, b3) sendo referentes a arestas de triangulos. Verifique se os triangulos são ...

presque 4 ans il y a

A résolu


Buzz
Dado um número inteiro n, retorne 'buzz' se esse valor for multiplo de 5, ou retorne o valor caso contrario. Buzz(5) = 'buzz'; ...

presque 4 ans il y a

A résolu


Juros Compostos
Faça uma função que receba um capital inicial (C), uma taxa de juros a ser aplicada (i) e um tempo (t) para qual será aplicado o...

presque 4 ans il y a

A résolu


List numbers that are not squares
The numbers 2, 3, 5, 6, 7, 8, 10, 11, 12, 13, 14, 15, 17, etc. are not perfect squares. Write a function to list the th term in ...

presque 4 ans il y a

A résolu


compter le nombre de zéros dans une matrice
écrire une fonction count_zeros qui prend en entrée une matrice M et détermine le nombre de zéros dans une matrice

presque 4 ans il y a

A résolu


sinus de pulsation a
Ecrire une fonction sinat qui prend en entrée un vecteur t (de valeurs croissantes) et renvoie un vecteur y de de même dimensi...

presque 4 ans il y a

A résolu


Intrication de deux vecteurs
Ecrire une fonction "intric" qui prend en entrée un vecteur ligne v1 et un vecteur ligne v2 et renvoie le vecteur ligne vres don...

presque 4 ans il y a

A résolu


Dominant Matrix - 01
A matrix is said to be diagonally dominant if for every row of the matrix, the magnitude of the diagonal entry in a row is large...

presque 4 ans il y a

A résolu


Play Outside In with primes

presque 4 ans il y a

A résolu


List Proth primes

presque 4 ans il y a

A résolu


Count the primes in Collatz sequences
Several Cody problems (21, 69, 42937, 44448, 44784, 52422) involve Collatz sequences. These start with a seed . If is odd, the ...

presque 4 ans il y a

A résolu


Find all prime factors of the input
Given an input x, find its all prime factors. Return the vector with all factors in ascending order. Efficiency is the key here...

presque 4 ans il y a

A résolu


Find distance travelled by an object starting from rest in time 't' and linear acceleration 'a' = 3t
Find distance travelled by an object starting from rest in time 't' with linear acceleration a = 3t. You are given time t as an ...

presque 4 ans il y a

A résolu


Draw 'W'
For any given n, return a matrix of height n and width 4n-3 containing a W of ones. Example: n=2 ans= [1 0 1 0 1 0 1 0 1 0...

presque 4 ans il y a

A résolu


Vector slither sort!
Sort a numeric vector in the following format: [largest value, smallest value, second largest value, second smallest value, etc...

presque 4 ans il y a

A résolu


determine skid distance of car
Determine the distance a car skids to a stop given initial velocity (v) and time (t).

presque 4 ans il y a

A résolu


Matrix Quadrants
Write a function that takes N as the input, and outputs a matrix whose upper-left (NxN) quadrant contains all ones, the lower-ri...

presque 4 ans il y a

A résolu


Find Closest Constant
Given a number x, return the value that is closest to x from this list of constants: 0, 1, , e, , (also known as ). For exampl...

presque 4 ans il y a

A résolu


Determine if x is a combination of m and n
Given positive integers x, m, and n, determine if x can be written as x = am + bn for any (non-negative) integers a and b. Your ...

presque 4 ans il y a

A résolu


Calculating Student Grades
The matrix grades contains raw grades for 7 students who took your course. Each row represents a different student. The first 7 ...

presque 4 ans il y a

A résolu


Calculate the mean of each half of a matrix
Given a matrix with an even number of columns, n, return a 1-by-2 row vector where the first element is the mean of all the elem...

presque 4 ans il y a

A résolu


Create an arrow matrix
An arrow matrix is a square matrix that contains ones on the diagonal, the last column, and last row. ...

presque 4 ans il y a

Charger plus