configurar seu nome
git config --global user.name "Seu Nome"
configurar seu email
git config --global user.email "exemplo@gmail.com"
escolha o editor de texto que sera usado pelo git
git config --global core.editor "gedit"
configurar seu nome
git config --global user.name "Seu Nome"
configurar seu email
git config --global user.email "exemplo@gmail.com"
escolha o editor de texto que sera usado pelo git
git config --global core.editor "gedit"
sudo apt install postgresql
sudo -u postgres psql
alter user postgres password 'postgres';
#include "stdlib.h" | |
// declaracoes das funcoes para por no ".h" | |
double mediana(int, double *); | |
double *moda(int, double *); | |
// ate aqui | |
// definicoes das funcoes |
i = 1 | |
while i <= 5: | |
print(i, input()) | |
i += 1 |
i = 1 | |
while i <= 5: | |
print(i, 'out') | |
i += 1 |
#!/usr/bin/env python3 | |
import tkinter | |
from time import strftime | |
def tic(): | |
rel['text'] = strftime('%H:%M:%S') | |
def tac(): | |
tic() | |
rel.after(1000, tac) |
# delete local tag '12345' | |
git tag -d 12345 | |
# delete remote tag '12345' (eg, GitHub version too) | |
git push origin :refs/tags/12345 | |
# alternative approach | |
git push --delete origin tagName | |
git tag -d tagName |
@Override | |
public void remove(T element) { | |
if (element != null) { | |
if(!isEmpty()) { | |
if(this.getData().equals(element)) { | |
this.setData(this.getNext().getData()); | |
if(!this.getNext().isEmpty()) { | |
this.setNext(this.getNext().getNext()); | |
} | |
} |
@SuppressWarnings("unchecked") | |
@Override | |
public T[] toArray() { | |
T[] result = null; | |
if (!this.isEmpty()) { | |
result = (T[]) new Object[1]; | |
result[0] = this.data; | |
result = this.juntaArrays(result, this.next.toArray()); | |
} | |
if (result == null) { |
import random | |
def merge_sort(xs): | |
"""Inplace merge sort of array without recursive. The basic idea | |
is to avoid the recursive call while using iterative solution. | |
The algorithm first merge chunk of length of 2, then merge chunks | |
of length 4, then 8, 16, .... , until 2^k where 2^k is large than | |
the length of the array | |
""" | |