@cleutonsampaio

inicio.go

November 22, 2021 · Go
package main

import (
	"fmt"
	"time"
)

func main() {

	timeNow := time.Now()
	fmt.Println("Current time: ", timeNow.String())

string inverter

updated July 31, 2021 · Python
if __name__=="__main__":
    nome=input("Informe seu nome: ")
    print(nome[::-1])
    

bhaskara

updated June 01, 2021 · Python
import math

def calc_delta(a,b,c):
    delta = b**2 - 4 * a * c 
    return delta
    
a = float(input("a: "))
b = float(input("b: "))
c = float(input("c: "))

delta = calc_delta(a, b, c)

meu_teste_fibonacci

May 31, 2021 · Python
def execute(x):
    fibonacci = (lambda x, x_1=1, x_2=0:
         x_2 if x == 0
         else fibonacci(x - 1, x_1 + x_2, x_1))
    return fibonacci(x)

if __name__=='__main__':
    print(execute(11))

fibonacci1

May 31, 2021 · Python
def execute(x):
    fibonacci = (lambda x, x_1=1, x_2=0:
         x_2 if x == 0
         else fibonacci(x - 1, x_1 + x_2, x_1))
    return fibonacci(x)

if __name__=='__main__':
    print(execute(11))

meu_fibonacci

May 31, 2021 · Python
def execute(x):
    x = 5 if x<2 or x>15 else x
    fibonacci = (lambda x, x_1=1, x_2=0:
         x_2 if x == 0
         else fibonacci(x - 1, x_1 + x_2, x_1))
    return fibonacci(x)

if __name__=='__main__':
    print(execute(11))

Lambda101-Multiplos-comandos-2

updated September 24, 2019 · Java
import java.util.*;
import java.lang.*;
import java.io.*;

// Lambda 101: Multiplos comandos

/**
 * Esta eh uma interface funcional, pois possui apenas um metodo abstrato.
 */ 
interface Bhaskara {
    public double delta(double a, double b, double c);

Lambda101-Funcional-interface-1

updated September 24, 2019 · Java
import java.util.*;
import java.lang.*;
import java.io.*;

// Lambda 101: Functional interface

/**
 * Esta eh uma interface funcional, pois possui apenas um metodo abstrato.
 */ 
interface Bhaskara {
 public double delta(double a, double b, double c);