๐
This file contains hidden or 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
#include <stdio.h> | |
#include <stdlib.h> | |
#include <math.h> | |
int main() { | |
int i, c; | |
double pi, x, dn; | |
dn = 1.00; | |
pi = 4.00; |
This file contains hidden or 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
const list = document.querySelectorAll('.list'); | |
for (let i = 0; i < list.length; i += 1) { | |
list[i].onclick = () => { | |
let j = 0; | |
while (j < list.length) { | |
list[j++].className = '.list'; | |
} | |
list[i].className = '.list active'; | |
} |
This file contains hidden or 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
const projectBtn = document.querySelector('#project-btn'); | |
const projectName = document.querySelector('#new-project'); | |
window.addEventListener('load', () => { | |
if(JSON.parse(localStorage.getItem('projects')) === null) { | |
localStorage.setItem('projects', JSON.stringify(new Array)); | |
} | |
displayProjects(); |
This file contains hidden or 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
require_relative 'enumerables' | |
=begin test variables | |
array_test = [1, 2, 3, 4, 5, 6] | |
obj_test = { one: 1, two: 2, three: 3 } | |
# Method call for tests each | |
puts '------------Original each--------------' | |
array_test.each { |e| p e**2 } | |
obj_test.each { |e| p e } |
This file contains hidden or 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
This is a code for autocomplete the address in forms using ViaCEP endpoint. | |
<script> | |
function clean_forms() { | |
document.getElementById('street').value = (''); | |
document.getElementById('district').value = (''); | |
document.getElementById('city').value = (''); | |
document.getElementById('uf').value = (''); | |
} | |
function my_cb(content) { |
NewerOlder