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
// Simple Todo API written in Go: Provides REST endpoints for managing todo items | |
// Endpoints: | |
// GET /todos - Get all todos | |
// POST /todos - Create a new todo | |
// GET /todos/:id - Get a specific todo | |
// PUT /todos/:id - Update a specific todo | |
// DELETE /todos/:id - Delete a specific todo | |
package main |
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
package main | |
import "fmt" | |
func binarySearchIterative(nums []int, target int) int { | |
start := 0 | |
end := len(nums) - 1 | |
for start <= end { | |
mid := start + (end-start)/2 |
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
package main | |
import ( | |
"fmt" | |
"io" | |
"log/slog" | |
"math/rand" | |
"os" | |
) |
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
""" | |
Pandas is a fast, powerful, flexible and easy to use open source data analysis and manipulation tool, | |
built on top of the Python programming language. | |
""" | |
import numpy as np | |
import pandas as pd | |
# Create a DataFrame | |
df = pd.read_csv('cars.csv') |