Skip to content

fun with JS #2#2

Closed
maciek-wozniak wants to merge 1 commit intoCodersLab:masterfrom
maciek-wozniak:master
Closed

fun with JS #2#2
maciek-wozniak wants to merge 1 commit intoCodersLab:masterfrom
maciek-wozniak:master

Conversation

@maciek-wozniak
Copy link
Copy Markdown

No description provided.

Copy link
Copy Markdown

@Ami777 Ami777 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Dobrze wykonane zadania.

});


function readFile(file) {
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Super. Na pewno czytelniejsza jest osobna funkcja.

fs.readFile(file, 'utf-8', (err, data) => {
if ((err === null)) {
let result = '';
data.split('').forEach((letter, index) => { (index % 2 === 0) ? result += letter.toUpperCase() : result += letter.toLowerCase(); });
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fajny pomysł :)

@maciek-wozniak maciek-wozniak closed this by deleting the head repository Mar 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants