Tasks

python

Sorting a Dictionary by Values

This Python code sorts a dictionary (my_dict) based on its values using the sorted() function...

json python

Python Code Snippet: Simple RESTful API with FastAPI

This Python snippet uses FastAPI to create a simple RESTful API for managing a list of books. It...

python

Close Futures Hedge Positions on Binance with CCXT Library.

This Python script uses the CCXT library to interact with Binance futures. It fetches open...

python

Python Threading for Concurrent Execution

This Python code demonstrates the use of threading to achieve concurrent execution of two...

python

Create a NumPy 1D Array

Discover how to create a one-dimensional array in Python using NumPy. This simple example...

nodejs graphql

GraphQL API Server with Node.js and Apollo Server

This snippet demonstrates how to build a basic GraphQL API server using Node.js with Apollo...

javascript

Simple WebSocket Server using 'ws' library

This Node.js code sets up a simple WebSocket server using the 'ws' library. It listens for...

javascript

Format Date

This JavaScript code defines a function formatDate to format a given date using...