Skip to content

Instantly share code, notes, and snippets.

View matteogobbi's full-sized avatar

Matteo Gobbi matteogobbi

View GitHub Profile
#EXTM3U
#EXTINF:-1 tvg-ID="Rai 1 FHD" tvg-name="Rai 1 FHD" tvg-logo="https://i.ibb.co/n7kGzBy/rai1.png" group-title="TVsat",Rai 1 FHD
https://devstreaming-cdn.apple.com/videos/streaming/examples/img_bipbop_adv_example_ts/master.m3u8
#EXTINF:-1 tvg-ID="Rai1 HD" tvg-name="Rai 1 HD" tvg-logo="https://i.ibb.co/n7kGzBy/rai1.png" group-title="TVsat",Rai 1 HD
https://devstreaming-cdn.apple.com/videos/streaming/examples/img_bipbop_adv_example_ts/master.m3u8
#EXTINF:-1 tvg-ID="" tvg-name="Rai 1 SD" tvg-logo="https://i.ibb.co/LZnGkyH/rai.jpg" group-title="TVsat",Rai 1 SD
https://devstreaming-cdn.apple.com/videos/streaming/examples/img_bipbop_adv_example_ts/master.m3u8
#EXTINF:-1 tvg-ID="Rai 2 Full HD" tvg-name="Rai 2 FHD" tvg-logo="https://i.ibb.co/fx0KGsT/rai2.png" group-title="TVsat",Rai 2 FHD
https://devstreaming-cdn.apple.com/videos/streaming/examples/img_bipbop_adv_example_ts/master.m3u8
#EXTINF:-1 tvg-ID="RAI 2 HD" tvg-name="Rai 2 HD" tvg-logo="https://i.ibb.co/fx0KGsT/rai2.png" group-title="TVsat",Rai 2 HD
/**
* Definition for singly-linked list.
* public class ListNode {
* int val;
* ListNode next;
* ListNode(int x) { val = x; }
* }
*/
public class Solution {
public boolean isPalindrome(ListNode head) {
import java.util.HashMap;
class TrieNode {
char letter;
HashMap<Character, TrieNode> children;
public TrieNode(char letter) {
this.letter = letter;
children = new HashMap<Character, TrieNode>();
}
@matteogobbi
matteogobbi / BlurredImage
Created June 20, 2014 23:29
iOS Blurred Image
- (UIImage *)blurredImageWithRadius:(CGFloat)radius iterations:(NSUInteger)iterations tintColor:(UIColor *)tintColor
{
//image must be nonzero size
if (floorf(self.size.width) * floorf(self.size.height) <= 0.0f) return self;
//boxsize must be an odd integer
uint32_t boxSize = (uint32_t)(radius * self.scale);
if (boxSize % 2 == 0) boxSize ++;
//create image buffers
@matteogobbi
matteogobbi / cancel_dispatcher_by_flag.m
Last active August 29, 2015 13:57
Block execution by a flag of blocks queued with dispatch_after.
//Flag
_isCancelled = @(NO);
//Create a queue
dispatch_queue_t queue = dispatch_queue_create("queue", NULL);
//Insert 3.000 blocks executed with a delay of 1 sec
for (int i=0; i<3000; i++) {
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(1* NSEC_PER_SEC)), queue, ^(void){
if(![_isCancelled boolValue])