-
Notifications
You must be signed in to change notification settings - Fork 35
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Atividade app.js #114
Open
LaisMariam
wants to merge
9
commits into
ifpb:master
Choose a base branch
from
LaisMariam:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Atividade app.js #114
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
effcbff
adicionando
LaisMariam 2646d70
adicionando
LaisMariam e662e2f
students
LaisMariam 6b6fc70
IMC
LaisMariam 4308109
eu
2844155
exercicios
LaisMariam b13ce33
atualizando os exercicios
LaisMariam 51fac5e
arquivo app.js
LaisMariam 1a662c0
atividade node languagens
LaisMariam File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
const weight = 200; | ||
const height = 1.5; | ||
const bmi = weight / height **2; | ||
let result; | ||
if (bmi < 18.5){ | ||
result = "underweight" | ||
}else if (bmi < 24.9){ | ||
result = 'normal weight' | ||
} else if (bmi < 29.9){ | ||
result = 'overweight' | ||
} else { | ||
result = 'obesity' | ||
} | ||
console.log(result) |
7 changes: 7 additions & 0 deletions
7
ecma/basic-harmonic-series/lais.maria/basic-harmonic-series.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
const tam = 10 | ||
let soma = 0 | ||
|
||
for (n = 1; n <= 10; n++){ | ||
soma+= 1/n; | ||
} | ||
console.log(soma) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
const nome = 'Luiz' | ||
console.log("Hello!" + nome) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
let imp; | ||
let salario = 3500.00; | ||
|
||
if (salario <= 1903.98){ | ||
imp = 0; | ||
} | ||
else if (salario < 2826.65){ | ||
imp = (salario * 7.5)/100 - 142.80; | ||
} | ||
else if (salario < 3751.05){ | ||
imp = (salario * 15.0)/100 - 354.80; | ||
} | ||
else if (salario < 4664.68){ | ||
imp = (salario * 22.5)/100 - 636.13; | ||
} | ||
else{ | ||
imp = (salario * 27.5)/100 - 869.36; | ||
} | ||
console.log(imp) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
let result = ''; | ||
|
||
for (let flag = 0; flag < 100; flag++){ | ||
if (flag < 10){ | ||
result+='0'+flag; | ||
}else{ | ||
result+=flag; | ||
} | ||
if (flag % 10 === 9){ | ||
result += '\n' | ||
}else{ | ||
result+= ' '; | ||
} | ||
} | ||
console.log(result) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
function soma(n1, n2){ | ||
some | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Laís Maria Paz Nóbrega de Lima |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
const http = require("http"); | ||
const url = require("url"); | ||
|
||
const hostname = "127.0.0.1"; | ||
const port = 3000; | ||
|
||
const server = http.createServer((req, res) => { | ||
res.statusCode = 200; | ||
res.setHeader("Content-Type", "text/plai; charset=utf-8"); | ||
//res.setEncoding('UTF-8'); | ||
|
||
// if (req.url === "pt") { | ||
// res.end("Olá mundo!"); | ||
// } else if (req.url === "en") { | ||
// res.end("Hello world!"); | ||
// } | ||
|
||
const hello = { | ||
"/pt": "Olá mundo!", | ||
"/en": "Hello world!" | ||
}; | ||
|
||
res.end(hello[req.url]); | ||
}); | ||
|
||
server.listen(port, hostname, () => { | ||
console.log(`Server running at http://${hostname}:${port}/`); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
const http = require("http") | ||
|
||
const hostname = "127.0.0.1"; | ||
const port = 3000; | ||
|
||
const server = http.createServer((req, res) => { | ||
res.statusCode = 200; | ||
res.setHeader('Content-Type', 'text/plain'); | ||
res.end('Hello World'); | ||
}); | ||
|
||
server.listen(port, hostname, () => { | ||
console.log(`Server running at http://${hostname}:${port}/`); | ||
}); | ||
|
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
return n1 + n2;