Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View gusthavosouza's full-sized avatar
🇮🇸
Working from 🇮🇸

Gustavo De Souza gusthavosouza

🇮🇸
Working from 🇮🇸
View GitHub Profile
@gusthavosouza
gusthavosouza / git-tag-delete-local-and-remote.sh
Created April 1, 2020 21:40 — forked from mobilemind/git-tag-delete-local-and-remote.sh
how to delete a git tag locally and remote
# 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
@gusthavosouza
gusthavosouza / Connectivity.java
Created April 4, 2016 14:11 — forked from emil2k/Connectivity.java
Android utility class for checking device's network connectivity and speed.
package com.emil.android.util;
import android.content.Context;
import android.net.ConnectivityManager;
import android.net.NetworkInfo;
import android.telephony.TelephonyManager;
/**
* Check device's network connectivity and speed
* @author emil http://stackoverflow.com/users/220710/emil
@gusthavosouza
gusthavosouza / setenv.sh
Created November 18, 2015 13:52 — forked from terrancesnyder/setenv.sh
./setenv.sh - example setenv.sh with defaults set for minimal time spent in garbage collection
#! /bin/sh
# ==================================================================
# ______ __ _____
# /_ __/___ ____ ___ _________ _/ /_ /__ /
# / / / __ \/ __ `__ \/ ___/ __ `/ __/ / /
# / / / /_/ / / / / / / /__/ /_/ / /_ / /
#/_/ \____/_/ /_/ /_/\___/\__,_/\__/ /_/
# Multi-instance Apache Tomcat installation with a focus
# on best-practices as defined by Apache, SpringSource, and MuleSoft
public class Recursao{
public static void main(String args[]){
metodo_recursivo(0);
}
public static void metodo_recursivo(int n){
if(n == 1001)
return;
System.out.println(n % 100 == 0 ? "print" : n);