Feeds
已解决
The Tower of Hanoi
In the <http://en.wikipedia.org/wiki/Tower_of_Hanoi Tower of Hanoi problem> with 3 rods (1, 2 & 3), the goal is to move a tower ...
26 days 前
已解决
Use a timetable to analyze a train timetable (Part 1)
Oh no, you missed your train to Boston! Find the departure time of the next available train by analyzing the train timetable. Th...
1 month 前
已解决
Sum of series VII
What is the sum of the following sequence: Σ(km^k)/(k+m)! for k=1...n for different n and m?
2 months 前
已解决
Convert Celsius temperature to Fahrenheit
Given a temperature in Celsius, return the equivalent in Fahrenheit. Formula: F = C * 9/5 + 32Example: cel2fahr(100) returns 212...
2 months 前
已解决
Triangle Area Using Heron's Formula
Given the three side lengths a, b, and c of a triangle, calculate its area using Heron's formula and round to 4 decimal places. ...
2 months 前
已解决
Count how many elements are above the mean
Given a vector, return the count of elements strictly greater than the mean of the vector. Example: above_mean_count([1 2 3 4 5]...
2 months 前
已解决
Reverse the characters of a string
Given a string, return the string with characters in reverse order. Example: rev_string('hello') returns 'olleh'
2 months 前
已解决
Find the nearest prime number
Happy 5th birthday, Cody! Since 5 is a prime number, let's have some fun looking for other prime numbers. Given a positive in...
2 months 前
已解决
Converting binary to decimals
Convert binary to decimals. Example: 010111 = 23. 110000 = 48.
3 months 前
已解决
Binary code (array)
Write a function which calculates the binary code of a number 'n' and gives the result as an array(vector). Example: Inpu...
3 months 前
已解决
Relative ratio of "1" in binary number
Input(n) is positive integer number Output(r) is (number of "1" in binary input) / (number of bits). Example: * n=0; r=...
3 months 前
已解决
Bit Reversal
Given an unsigned integer _x_, convert it to binary with _n_ bits, reverse the order of the bits, and convert it back to an inte...
3 months 前
已解决
Binary numbers
Given a positive, scalar integer n, create a (2^n)-by-n double-precision matrix containing the binary numbers from 0 through 2^n...
3 months 前
已解决
Estimating Battery Lifetime Based on Load Profile and Depth of Discharge (DoD)
In a Battery Management System (BMS), the lifetime of a battery depends on various factors, including the Depth of Discharge (Do...
3 months 前
已解决
Estimating the Range of an Electric Vehicle (EV)
In Electric Vehicles (EVs), the driving range is the estimated distance a vehicle can travel on a fully charged battery. The ran...
3 months 前
已解决
Estimating Battery Backup Time for an Inverter
In a Battery Management System (BMS), estimating the backup time of a battery-powered inverter helps determine how long it can s...
3 months 前
已解决
Battery Charge Rate Calculation
In a Battery Management System (BMS), the charge rate () of a battery can be calculated using the formula: where: is th...
3 months 前
已解决
Battery State of Health (SoH) Calculation
In a Battery Management System (BMS), the State of Health (SoH) of a battery is an indicator of its overall condition. It is cal...
3 months 前
已解决
Battery Charge Efficiency Calculation
In a Battery Management System (BMS), the efficiency of battery charging can be estimated using the formula: where: is the...
3 months 前
已解决
Battery Voltage Drop Estimation
In a Battery Management System (BMS), the voltage drop (V_drop) due to the load can be calculated using the formula:V_drop=I×R ...
3 months 前
已解决
Battery Discharge Time Estimation
In a Battery Management System (BMS), the estimated discharge time (T) of a battery can be calculated as: where: is the ...
3 months 前
已解决
State of Charge (SoC) Estimation for a Battery
The State of Charge (SoC) of a battery represents its remaining charge as a percentage. It can be calculated using the formula: ...
3 months 前
已解决
Battery Life Estimation for a Device
A battery-powered device consumes a constant current while operating. The estimated battery life (T) can be calculated using the...
3 months 前
已解决
Find a Pythagorean triple
Given four different positive numbers, a, b, c and d, provided in increasing order: a < b < c < d, find if any three of them com...
4 months 前
已解决
Length of a short side
Calculate the length of the short side, a, of a right-angled triangle with hypotenuse of length c, and other short side of lengt...
4 months 前
已解决
Prime factor digits
Consider the following number system. Calculate the prime factorization for each number n, then represent the prime factors in a...
4 months 前
已解决
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:/...
4 months 前
已解决
Project Euler: Problem 6, Natural numbers, squares and sums.
The sum of the squares of the first ten natural numbers is, 1^2 + 2^2 + ... + 10^2 = 385 The square of the sum of the first ...
4 months 前
已解决
Project Euler: Problem 5, Smallest multiple
2520 is the smallest number that can be divided by each of the numbers from 1 to 10 without any remainder. What is the smalle...
4 months 前
已解决
Project Euler: Problem 3, Largest prime factor
The prime factors of 13195 are 5, 7, 13 and 29. What is the largest prime factor of the number being input, input might be ui...
4 months 前




