Skip to content

Instantly share code, notes, and snippets.

View joydeepsaha05's full-sized avatar

Joydeep Saha joydeepsaha05

  • India
View GitHub Profile
@joydeepsaha05
joydeepsaha05 / url_validator.dart
Created September 6, 2018 14:37
Checks whether the given URL is valid. Extracted from https://github.com/karan/validator.dart to support Dart2.
class URLValidator {
RegExp _ipv4Maybe =
new RegExp(r'^(\d?\d?\d)\.(\d?\d?\d)\.(\d?\d?\d)\.(\d?\d?\d)$');
RegExp _ipv6 =
new RegExp(r'^::|^::1|^([a-fA-F0-9]{1,4}::?){1,7}([a-fA-F0-9]{1,4})$');
_shift(List l) {
if (l.length >= 1) {
var first = l.first;
@joydeepsaha05
joydeepsaha05 / OpenCV_Test.py
Created August 1, 2017 12:48
Detects Magenta and Green colours using the webcam. Get the colours from here: https://www.ledr.com/colours/multi.htm
import cv2
import numpy as np
cap = cv2.VideoCapture(0)
while 1:
# Take each frame
_, frame = cap.read()