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
| /** | |
| * Programa em Java para contar as ocorrências de cada letra em uma frase. | |
| * | |
| * @author Celso Jr | |
| * @version Imperativa | |
| * | |
| */ | |
| import java.io.*; |
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
| open System | |
| let (<->) x y = 2 * x + y = 1 | |
| let a = [ -1..5 ];; let b = [ -3..8 ];; | |
| let axb = a |> List.collect (fun c -> b |> List.map (fun d -> c,d)) | |
| |> List.choose (fun (a,b) -> | |
| match (a,b) with | |
| | x when a <-> b -> Some(a,b) | |
| | _ -> None) |
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
| (*-------------------------------------------------------------------------------------------- | |
| * Copyright (c) 2017 Celso Junior, celsojrfull@gmail.com. All rights reserved. | |
| * Licensed under the MIT License. See License.txt in the project root for license information. | |
| * F# Tail Recursive Factorial in a functional programming approach. | |
| * Also using the CPS technique (Continuation Passing Style). | |
| * Ref.: https://en.wikipedia.org/wiki/Continuation-passing_style | |
| * --------------------------------------------------------------------------------------------*) | |
| [<TailCall>] | |
| let fac1 x = |
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
| // F# calculating the factorial in imperative approach programming. | |
| let Fact n = | |
| let mutable x = n | |
| let mutable y = 1 | |
| while x > 0 do | |
| y <- y * x | |
| x <- (x - 1) | |
| y | |
| for i in 0 .. 10 do |
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
| /* | |
| * ////////////////////////// MAPA FILA BANCO C# ////////////////////////////// | |
| * Atividade MAPA desenvolvida para ajudar os amigos da faculdade UniCesumar | |
| * Trata-se de uma simples implementação de um atendimento de uma fila de | |
| * banco utilizando os recursos da linguagem c# 6 | |
| * | |
| * Copyright(c) 2016 Celso Junior, celsojrfull@gmail.com | |
| * | |
| * Licensed under MIT-style license: | |
| * |
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
| /* | |
| * ////////////////////////// MAPA FILA BANCO ////////////////////////////// | |
| * Atividade MAPA desenvolvida para ajudar os amigos da faculdade UniCesumar | |
| * Trata-se de uma simples implementação de um atendimento de uma fila | |
| * de banco utilizando os recursos da fila encadeada da linguagem c | |
| * | |
| * Copyright(c) 2016 Celso Junior, celsojrfull@gmail.com | |
| * | |
| * Licensed under MIT-style license: | |
| * |
NewerOlder