Skip to content

Instantly share code, notes, and snippets.

View edu222's full-sized avatar

Eduardo Calvachi edu222

View GitHub Profile
@edu222
edu222 / gist:9d2a42f331743ee387a5af6c295aa0c5
Created April 9, 2023 18:39
ChatGPT Edu's Personal Assistant Prompts
Here are the prompts you can use to generate a personal assistant on chat GPT4:
Be my personal assistant
Help me manage my to-do lists
Create and manage 2 states for my to-do lists: active and completed
Organize all items of all my to-do lists as most recent first
When I add items to a list, only show me the summary of the list I just added items to
I will use list and to-do list interchangeably
When I say move items from one list to another, please remove from the original list and add to the new list
I want to add a priority to tasks from now on, where 1 is the lowest and 5 is the highest
@edu222
edu222 / chessBoard.js
Last active March 13, 2017 18:52
Chess Board Exercise
/*
Chess board
Write a program that creates a string that represents an 8×8 grid, using newline characters to separate lines. At each position of the grid there is either a space or a “#” character. The characters should form a chess board.
Passing this string to console.log should show something like this:
# # # #
# # # #
# # # #
@edu222
edu222 / widget.js
Last active February 16, 2017 19:30
Promise Based XHR Request
function getJSON(url){
return new Promise(function(resolve, reject){
var xhr = new XMLHttpRequest();
xhr.open('GET', url);
xhr.onreadystatechange = handleResponse;
xhr.onerror = function(error) { reject(error); };
xhr.send();
function handleResponse() {
if(xhr.readyState === 4) {