Skip to content

Instantly share code, notes, and snippets.

View ezefranca's full-sized avatar
💻
👨🏻‍💻

Ezequiel Santos ezefranca

💻
👨🏻‍💻
View GitHub Profile
<script>
function loadPublications() {
 const publicationsURL = "https://gist.githubusercontent.com/your_username/gist_id/raw/publications.json";
 
 fetch(publicationsURL)
 .then(response => {
 if (!response.ok) {
 throw new Error('Network response was not ok');
 }
 return response.json();
<link rel=”stylesheet” href=”https://cdnjs.cloudflare.com/ajax/libs/academicons/1.9.1/css/academicons.min.css">
!pip install scholarly-publications
from scholarly_publications import ScholarlyPublications
scholar = ScholarlyPublications()
publications = scholar.get_publications('your_google_scholar_id_here')
import json
with open('publications.json', 'w') as f:
 json.dump(publications, f)
@ezefranca
ezefranca / universities_visit.json
Created January 20, 2025 17:01
universities_visit.json
[
{
"year": 2009,
"country_flag": "🇧🇷",
"country_name": "Brazil",
"university_name": "Faculdade De Tecnologia Senai Anchieta (SENAI-SP)",
"url": null,
"description": "Studied Mechatronics Technician, graduated in 2009. At that time, the institution was transitioning from a Technical School to a University, granting us access to new labs and an upgraded library with a wealth of new books."
},
{
@ezefranca
ezefranca / gcd_euclidean.swift
Created July 26, 2024 11:18
A Swift function to compute the greatest common divisor (GCD) of two integers using the Euclidean algorithm.
/// Computes the greatest common divisor (GCD) of two integers using the Euclidean algorithm.
/// - Parameters:
/// - a: An integer value.
/// - b: Another integer value.
/// - Returns: The greatest common divisor of `a` and `b`.
func gcd(_ a: Int, _ b: Int) -> Int {
b == 0 ? a : gcd(b, a % b)
}
// Example usage
[
{
"title": "Brain\u2013machine interfaces: past, present and future",
"year": "2006",
"link": "https://scholar.google.com/citations?view_op=view_citation&hl=en&user=RefX_60AAAAJ&pagesize=100&citation_for_view=RefX_60AAAAJ:9yKSN-GCB0IC",
"citations": "2356"
},
{
"title": "Learning to control a brain\u2013machine interface for reaching and grasping by primates",
"year": "2003",
[
{
"title": "Dependency Management in iOS Development: A Developer Survey Perspective",
"year": "2024",
"link": "https://scholar.google.com/citations?view_op=view_citation&hl=en&user=6nOPl94AAAAJ&pagesize=100&sortby=pubdate&citation_for_view=6nOPl94AAAAJ:hqOjcs7Dif8C",
"citations": "0"
},
{
"title": "Apple Vision Pro: Comments in Healthcare",
"year": "2024",
require 'nokogiri'
require 'open-uri'
Encoding.default_external = 'UTF-8'
query = params['query'] || 'banana'
page = (params['page'] || 0).to_i
MAX_ATTEMPTS = 10
attempts = 0
doc = nil
require 'nokogiri'
require 'open-uri'
Encoding.default_external = 'UTF-8'
query = params['query'] || 'banana'
page = (params['page'] || 0).to_i
url = "https://www.elcorteingles.pt/supermercado/pesquisar/" + (page > 0 ? "#{page}" : "") + "?term=#{query}&search=text"
document = Nokogiri::HTML(open(url, read_timeout: 30))
@ezefranca
ezefranca / pingodoce.rb
Created March 13, 2023 19:25
Quem trouxe, quem trouxe.
require 'net/http'
require 'json'
Encoding.default_external = 'UTF-8'
query = params['query'] || 'banana'
page = (params['page'] || 0).to_i
from = page * 100
uri = URI('https://mercadao.pt/api/catalogues/6107d28d72939a003ff6bf51/products/search')
uri.query = URI.encode_www_form({