Code-Pulse
Untitled Session
Save
Run Code
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
// Welcome to Code-Pulse Live!
// Connect your heart rate
monitor
(Bluetooth) or enable webcam pulse detection
// to see your biometrics sync with code execution in real-time.
// Example: Calculate prime numbers
5
">"text-chart-
4
">function
isPrime
(n) {
5
">"text-chart-
4
">if (n <
2
)
5
">"text-chart-
4
">return false;
5
">"text-chart-
4
">for (
5
">"text-chart-
4
">let i =
2
; i <= Math.
sqrt
(n); i++) {
5
">"text-chart-
4
">if (n % i ===
0
)
5
">"text-chart-
4
">return false; }
5
">"text-chart-
4
">return true; } console.
log
(
5
">"Finding prime numbers
4
5
">">from
1
to
50
..."); console.
log
(
5
">"");
5
">"text-chart-
4
">const primes = [];
5
">"text-chart-
4
">for (
5
">"text-chart-
4
">let i =
1
; i <=
50
; i++) {
5
">"text-chart-
4
">if (
isPrime
(i)) { primes.
push
(i); } } console.
log
(
5
">"Primes found:", primes.
join
(
5
">", ")); console.
log
(
5
">"Total primes:", primes.length); console.
log
(
5
">""); console.
log
(
5
">"Watch your pulse visualizer react!");
// Welcome to Code-Pulse Live! // Connect your heart rate monitor (Bluetooth) or enable webcam pulse detection // to see your biometrics sync with code execution in real-time. // Example: Calculate prime numbers function isPrime(n) { if (n < 2) return false; for (let i = 2; i <= Math.sqrt(n); i++) { if (n % i === 0) return false; } return true; } console.log("Finding prime numbers from 1 to 50..."); console.log(""); const primes = []; for (let i = 1; i <= 50; i++) { if (isPrime(i)) { primes.push(i); } } console.log("Primes found:", primes.join(", ")); console.log("Total primes:", primes.length); console.log(""); console.log("Watch your pulse visualizer react!");
Terminal Console
System ready. Awaiting execution signal...
Biometrics
Offline
Status:
Disconnected
Connect Sensor
Bluetooth
Webcam
Current Heart Rate
--
bpm
Live Pulse