Skip to content

Instantly share code, notes, and snippets.

View EdmaryBaga's full-sized avatar

Edith Bautista EdmaryBaga

View GitHub Profile
@EdmaryBaga
EdmaryBaga / Introduction.swift
Created July 23, 2024 20:40
Introduction to Swift
/*Variables*/
var MyFood = "Pozole"
print("Hoy comere \(MyFood)")
/*CONSTANTE*/
let greeting = "Hello, world!"
/*String multiples lineas*/
@EdmaryBaga
EdmaryBaga / collections.kt
Last active August 17, 2023 20:17
Collections with kotlin
fun main() {
val myArray : Array<String> = arrayOf("pear", "strawnberries","apple")
myArray.set(1,"mango")
traverseArray(myArray)
/*Matriz*/
var myMatriz = arrayOf(
myArray,
arrayOf(1,2,3,4),
@EdmaryBaga
EdmaryBaga / KotlinTypeData.kt
Last active August 15, 2023 00:17
Se explica lo que son los tipos de datos y sus caracteristicas
class MyClass{
/*Una constante siempre debe ir dentro de un companion*/
companion object {
const val moneda = "Euro"
}
fun myFun() {
val name = "Carmen" //los valores val no pueden ser modificados
@EdmaryBaga
EdmaryBaga / POOwith.dart
Created March 28, 2021 06:47
In this file I create a abstraction and use a pattern factoy as a practice the clean code
void main() {
Employe myEmploye = new Employe("Edith", "fulltime", 5 );
Employe myFreelanceEmploye = new Employe("Edith", "freelance", 5 );
SalaryCalculator mySalaryCalculator = new SalaryCalculator();
double yourSalary = mySalaryCalculator .calculateSalary(myEmploye);
double yourFreelanceSalary = mySalaryCalculator .calculateSalary(myFreelanceEmploye);
@EdmaryBaga
EdmaryBaga / ExamplesOCP.dart
Last active December 23, 2020 19:48
En este dart, presento algunos ejemplos de código usando Open closed principle de SOLID, como ejercicio para entender mejor este tema y poder aplicarlo a mis proyectos, y de esa forma tener desarrollos de mejor calidad
================== SALARY CALCULATOR ================================
void main() {
Employe myEmploye = new Employe("Edith", "fulltime", 5 );
Employe myFreelanceEmploye = new Employe("Maribel", "freelance", 5 );
SalaryCalculator mySalaryCalculator = new SalaryCalculator();
double yourSalary = mySalaryCalculator .calculateSalary(myEmploye);
@EdmaryBaga
EdmaryBaga / AndroidStudio.txt
Created July 15, 2020 00:57
Apuntes de algunas configuraciones que me gustan tener en Android Studio para trabajar mas eficientemente
--Keymapping
File -> Settings -> Keymap, clic derecho sobre el avento y seleccionar add despues agregar la combinacion de teclas para ese evento
/// -----------------------* * * TEORIA * * * -----------------------
Stream/Observable
listen/suscribe Configurar el “trap”.
StreamController/Subject
StreamController/Subject
/***************************************** EJEMPLO 1***********************************/
//necesario para usar los streams
import 'dart:async';
@EdmaryBaga
EdmaryBaga / gist:dfe1eb7c32e727d18fc67bccbd00624c
Created July 1, 2020 23:59 — forked from rxaviers/gist:7360908
Complete list of github markdown emoji markup

People

:bowtie: :bowtie: 😄 :smile: 😆 :laughing:
😊 :blush: 😃 :smiley: ☺️ :relaxed:
😏 :smirk: 😍 :heart_eyes: 😘 :kissing_heart:
😚 :kissing_closed_eyes: 😳 :flushed: 😌 :relieved:
😆 :satisfied: 😁 :grin: 😉 :wink:
😜 :stuck_out_tongue_winking_eye: 😝 :stuck_out_tongue_closed_eyes: 😀 :grinning:
😗 :kissing: 😙 :kissing_smiling_eyes: 😛 :stuck_out_tongue:
@EdmaryBaga
EdmaryBaga / appViewPage.dart
Last active May 19, 2020 22:48
En esta versión se pinta un PageView builder infinito
import 'package:flutter/material.dart';
class appPageView extends StatefulWidget {
appPageView({Key key}) : super(key: key);
@override
_appPageViewState createState() => _appPageViewState();
}
class _appPageViewState extends State<appPageView> {
@EdmaryBaga
EdmaryBaga / ListaInfinita.dart
Created May 19, 2020 22:21
En este Dart se implemento una Lista infinita que se llena con palabras aleatorias de la librería english_words y con el icono que se encuentra de lado izquierdo guarda en una lista de favoritos que se muestra en un segundo Scraffold
import 'package:flutter/material.dart';
import 'dart:math';
import 'package:english_words/english_words.dart';
class App extends StatefulWidget {
App({Key key}) : super(key: key);
@override
_AppState createState() => _AppState();
}