Skip to content

Instantly share code, notes, and snippets.

@cesar
cesar / foo.js
Last active June 16, 2020 14:55
if (embedded) {
if (embedded['wp:featuredmedia']) {
if (embedded['wp.featuredmedia'][0]) {
...
}
}
}
// Usando lodash get
import get from 'lodash/get'
@cesar
cesar / container.js
Last active April 21, 2020 17:41 — forked from rocaiguina/container
import React, { Component } from 'react';
import { View } from 'react-native';
export function Post ({ title, embedded }) {
return (
<View style={styles.smallPost}>
<View style={styles.smallTextBlock}>
<H3>{title.rendered}</H3>
</View>
{embedded['wp:featuredmedia'] ? (
@cesar
cesar / poli.py
Last active March 22, 2020 19:46
import csv
import os
from difflib import get_close_matches
import shutil
import re
import copy
def sanitize_name(name):
return re.sub(r"(\((\w*|\s)*\)|\.|\s)", '', name).lower()
function fakeFetchData(url, args) {
return new Promise((resolve, reject) => {
setTimeout(function() {
// here in the resolve, you can pass any object that you want
// to simulate the server response
return resolve({
posts: [
{
id: 1,
title: 'Somthing goes here',
  1. Create calculators for the following equations:
    1. BMI
    2. BAC
    3. BMR
  2. Find the sum of all the numbers in an array
  3. Given an array of numbers determine what is the average number of the array
  4. Find the largest number in the array. How would you modify the code to find the smallest number in the array
  5. Given an array of numbers, print to STDOUT how many numbers are negative, how many are positive, and how many are 0
  6. Given an array of items (they can be numbers) and two index positions, if the positions are valid, swap the two items in the array and return a new copy of the array.
  7. Given an array of numbers, arrange in ascending fashion (sort them) the smallest element should be in the left-most side of the array and the biggest element should be in the right-most side of the array. *Don't use any STDLIB function for

Hey ma, no hands!

Still no hands!

I lied, there were hands involved

Keybase proof

I hereby claim:

  • I am cesar on github.
  • I am cesarcruz (https://keybase.io/cesarcruz) on keybase.
  • I have a public key ASBvxOLQSGteFbBDSBkWBFaZavKFaSBBjUTOmoZVoovf-Ao

To claim this, I am signing this object:

{
"ref": "refs/heads/gh-pages",
"before": "4d2ab4e76d0d405d17d1a0f2b8a6071394e3ab40",
"after": "7700ca29dd050d9adacc0803f866d9b539513535",
"created": false,
"deleted": false,
"forced": false,
"base_ref": null,
"compare": "https://github.com/baxterthehacker/public-repo/compare/4d2ab4e76d0d...7700ca29dd05",
"commits": [
My name is César Cruz. I’m a computer engineering student from University of Puerto Rico graduating this coming fall. Browsing through Hacker News I saw your job posting; I consider myself a good fit for <the job position>.
I have previous experience using jQuery Mobile, NodeJS using Express and MySQL (https://github.com/joframart/LlamaBucket and https://github.com/sezalcru/llama_bucket) I’ve also worked with projects for the government of Puerto Rico (https://github.com/commonwealth-of-puerto-rico/PuertoRicoByPuertoRicans) using Node, Bootstrap and MongoDB
During this past summer, I was an intern over at Goldman Sachs at New York City. I spent the summer working on designing and implementing an API, using Java (Jersey Framework) and Cassandra, that would be used by other applications in the division. There was strong emphasis on design patterns and testability which I was able to pick up with the help of the team.
Each of these experiences has taught me a lot and I strongly believe that I can contribute t