Snippets Collections
sudo docker run -itd \
-p 9090:9090-p 9000:9000\
--name minio --restart=always \
-e "MINIO_ROOT_USER=admin" \
-e "MINIO_ROOT_PASSWORD=<password>" \
-v /path/to/data:/data \
minio/minio  server /data --console-address ":9090" -address ":9000"
version: '3.9'

services:
  prometheus:
    image: prom/prometheus:latest
    container_name: prometheus
    hostname: prometheus
    command:
      - '--config.file=/etc/prometheus/prometheus.yml'
    ports:
      - 9090:9090
    stdin_open: true
    tty: true
    restart: always
    environment:
      TZ: "Europe/Moscow"
    volumes:
      - ./prometheus/:/etc/prometheus/
      - prom_data:/prometheus
    networks:
     default:
      ipv4_address: 172.28.0.101
  grafana:
    image: grafana/grafana
    container_name: grafana
    ports:
      - 3000:3000
    stdin_open: true
    tty: true
    restart: always
    environment:
      - GF_SECURITY_ADMIN_USER=admin
      - GF_SECURITY_ADMIN_PASSWORD=grafana
    volumes:
      - ./grafana:/etc/grafana/provisioning/datasources
    links:
      - prometheus
    networks:
     default:
      ipv4_address: 172.28.0.102
  node_exporter:
    image: prom/node-exporter
    container_name: exporter
    hostname: exporter
    command:
      - --path.procfs=/host/proc
      - --path.sysfs=/host/sys
      - --collector.filesystem.ignored-mount-points
      - ^/(sys|proc|dev|host|etc|rootfs/var/lib/docker/containers|rootfs/var/lib/docker/overlay2|rootfs/run/docker/netns|rootfs/var/lib/docker/aufs)($$|/)
    pid: host
    environment:
      TZ: "Europe/Moscow"
    restart: always
    volumes:
      - /proc:/host/proc:ro
      - /sys:/host/sys:ro
      - /:/rootfs:ro
    ports:
      - "9100:9100"
    networks:
     default:
      ipv4_address: 172.28.0.103
  alertmanager:
    image: prom/alertmanager:latest
    container_name: alertmanager
    hostname: alertmanager
    ports:
      - 9093:9093
    volumes:
      - ./alertmanager/:/etc/alertmanager/
      - alertmanager-data:/data
    restart: always
    command:
      - '--config.file=/etc/alertmanager/alertmanager.yml'
      - '--storage.path=/alertmanager'
    networks:
     default:
      ipv4_address: 172.28.0.104
networks:
  default:
    ipam:
      driver: default
      config:
        - subnet: 172.28.0.0/16
volumes:
  prom_data:
  alertmanager-data:
:root{
  --blue:#09f;
  --light:color-mix(in srgb, var(--blue), red 50%);
}
.text{
  font-size:100px;
  color:var(--light);
}
module.exports = {
  content: ['./src/**/*.{html,js,tsx}', './components/**/*.{js,ts,jsx,tsx}'],
  theme: {
    extend: {
      colors: {
        primaryColor: '#E17446',
        primaryColorHover: '#db5b24',
        primaryText: '#111130',
        primaryBlue: '#2b5a9c',
        textLight: '#9e9ebc',
        Gray: '#8f9bad',
        f6f9fd: '#f6f9fd',
        dddddd: '#dddddd',
        inputborder: '#e8e8e8',
        borderColor: '#ebebeb',
        green: '#008f02',
        lightGreen: '#e2f2e2',
        orange: '#f05c00',
        orangeLight: '#fcede4',
        redLight: '#fde5e5',
        red: '#f00000',
        border1: '#ebebeb',

        themecolor: '#E17446',
        hoverthemecolor: '#db5b24',
      },
      backgroundImage: {
        close: 'url(/public/images/colse.png)',
        trendBG1: 'url(../../public/images/blog-img.jpg)',
      },
      boxShadow: {
        inputFocus:
          'rgba(0, 0, 0, 0.1) 0px 1px 3px 0px, rgba(0, 0, 0, 0.06) 0px 1px 2px 0px',
        headerFix: 'rgba(0, 0, 0, 0.1) 0px 10px 50px',
        sibarToggle: '-4px 5px 5px #0000000d',
        sibarToggleRTL: '5px -4px 6px #0000000d',
      },
      spacing: {
        '5px': '5px',
        '10px': '10px',
        '14px': '14px',
        '15px': '15px',
        '18px': '18px',
        '20px': '20px',
        '25px': '25px',
        '30px': '30px',
        '35px': '35px',
        '40px': '40px',
        '45px': '45px',
        '50px': '50px',
        '55px': '55px',
        '60px': '60px',
        '65px': '65px',
        '70px': '70px',
        '75px': '75px',
        '80px': '80px',
        '85px': '85px',
        '90px': '90px',
        '95px': '95px',
        '100px': '100px',
        '106px': '106px',
        '120px': '120px',
        unset: 'unset',
      },
      fontFamily: {
        charter: 'var(--charterFont)',
        sohne: 'var(--sohneFont)',
        poppins: 'var(--poppins)',
        gloock: 'var(--gloock)',
      },
      fontSize: {
        0: '0',
        '5px': '5px',
        '10px': '10px',
        '14px': '14px',
        '15px': '15px',
        '16px': '16px',
        '17px': '17px',
        '20px': '20px',
        '22px': '22px',
        '25px': '25px',
        '28px': '28px',
        '30px': '30px',
        '35px': '35px',
        '40px': '40px',
        '45px': '45px',
        '50px': '50px',
        '55px': '55px',
        '60px': '60px',
        '65px': '65px',
        '70px': '70px',
        '75px': '75px',
        '80px': '80px',
        '85px': '85px',
        '90px': '90px',
        '95px': '95px',
        '100px': '100px',
        unset: 'unset',
      },
      lineHeight: {
        1: '1',
        '5px': '5px',
        '10x': '10px',
        '15px': '15px',
        '19px': '19px',
        '22px': '22px',
        '20px': '20px',
        '25px': '25px',
        '28px': '28px',
        '30px': '30px',
        '32px': '32px',
        '35px': '35px',
        '36px': '36px',
        '40px': '40px',
        '42px': '42px',
        '46px': '46px',
        '45px': '45px',
        '50px': '50px',
        '52px': '52px',
        '55px': '55px',
        '60px': '60px',
        '65px': '65px',
        '70px': '70px',
        '75px': '75px',
        '80px': '80px',
        '85px': '85px',
        '90px': '90px',
        '95px': '95px',
        '100px': '100px',
        unset: 'unset',
        Normal: 'normal',
      },
      zIndex: {
        1: '9',
        2: '99',
        3: '999',
        4: '9999',
        5: '99999',
        6: '999999',
      },
      borderRadius: {
        '5px': '5px',
        '10px': '10px',
        '15px': '15px',
      },
      screens: {
        768: '768px',
        992: '992px',
        1200: '1200px',
        1300: '1300px',
        1400: '1400px',
        1500: '1500px',
        1600: '1600px',
        1700: '1700px',
      },
      animation: {
        slow: 'wiggle 2s linear',
      },
      keyframes: {
        wiggle: {
          '0%': { transform: 'transform(164.25px)' },
          '100%': { transform: 'rotate(0px)' },
        },
      },
    },
  },
}
.header {
  padding: 1.5rem 0;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: $white;
  z-index: 99;
  @include transition(300ms);

  @media (min-width: $lg) {
    padding: 3rem 0;
  }

  &.sticky {
    background: $white !important;
    padding: 2rem 0;
  }

  &--transperant {
    background: transparent;
  }

  &__logo-link {

    img,
    svg {
      float: left;
      height: auto;
      // height: 100%;
      width: 100%;
      width: auto;

      @media (min-width: $sm) {
        height: 50px;
      }

      @media (min-width: $xl) {
        height: 60px;
      }
    }
  }

  &-btn {
    margin-top: 1rem;
    display: flex;
    justify-content: center;
    position: relative;

    @media (min-width:$lg) {
      margin-top: 0;
      display: inline-block;
    }

    @media (min-width:$lg) {
      margin-left: 4.5rem !important;
    }

    a {
      border-radius: 0 15px 0 15px;
      width: auto !important;
      padding: 7px 25px !important;
      font-size: 1.5rem !important;
      line-height: 2.2rem !important;

      @media (min-width: $xl) {
        padding: 5px 43px 5px 30px !important;
        line-height: 3rem !important;
      }
    }
  }

  &__burger {
    background-color: transparent;
    border: none;
    cursor: pointer;
    display: flex;
    padding: 0;
    float: right;
    position: relative;
    z-index: 10;

    @media (min-width: $lg) {
      display: none;
    }

    .line {
      fill: none;
      stroke: $primary;
      stroke-width: 6;
      transition: stroke-dasharray 600ms cubic-bezier(0.4, 0, 0.2, 1),
        stroke-dashoffset 600ms cubic-bezier(0.4, 0, 0.2, 1);
    }

    .line1 {
      stroke-dasharray: 60 207;
      stroke-width: 6;
    }

    .line2 {
      stroke-dasharray: 60 60;
      stroke-width: 6;
    }

    .line3 {
      stroke-dasharray: 60 207;
      stroke-width: 6;
    }

    &.opened .line1 {
      stroke-dasharray: 90 207;
      stroke-dashoffset: -134;
      stroke-width: 6;
    }

    &.opened .line2 {
      stroke-dasharray: 1 60;
      stroke-dashoffset: -30;
      stroke-width: 6;
    }

    &.opened .line3 {
      stroke-dasharray: 90 207;
      stroke-dashoffset: -134;
      stroke-width: 6;
    }
  }

  .col-lg-10 {
    position: static;
  }

  .nav-main {
    float: right;
    display: none;
    position: absolute;
    right: 0;
    padding: 50px 15px;
    width: 100%;
    top: calc(100% + 0px);
    background: $white;
    height: calc(100vh - 80px);

    @media (min-width: $lg) {
      height: auto;
      position: static;
      background: none;
      padding: 0;
      max-width: none;
      width: auto;
      display: flex !important;
      align-items: center;
    }

    @media (max-width: 991px) {
      overflow: auto;
    }

    .primary {
      display: block;
      float: left;
      margin: 0;
      padding: 0;
      width: 100%;
      text-align: center;

      @media (min-width: $lg) {
        text-align: left;
        display: flex;
        align-items: center;
      }
    }

    .menu {
      display: block;
      float: left;
      margin: 0;
      padding: 0;

      &-item {
        float: left;
        padding: 0;
        width: 100%;

        @media (min-width: $lg) {
          margin: 0 5px;
          width: auto;
        }

        i.dropdown-arv {
          position: absolute;
          right: 15px;
          width: 12px;
          height: 12px;
          text-align: center;
          top: 43%;
          z-index: 5;
          border-top: 2px solid $dark;
          border-right: 2px solid $dark;
          transform: translateY(-50%) rotate(135deg);

          &.active {
            transform: rotate(-45deg);
            content: "-";
          }
        }

        .dropdown-arv-cont {
          position: absolute;
          top: 4px;
          right: 18%;
          z-index: 5;
          width: 44px;
          height: 100%;
          @include transition(300ms);

          @media (min-width: $sm) {
            right: 35%;
          }

          @media (min-width: $md) {
            right: 40%;
          }

          @media (min-width: $lg) {
            display: none;
          }

          &.active {
            transform: rotate(180deg);
            @include transition(300ms);
          }
        }

        &:before {
          display: none;
        }

        &:first-child {
          margin-left: 0;
        }

        &:last-child {
          margin-right: 0;
        }

        a {
          position: relative;
          font-family: $Quicksand;
          font-weight: $normal;
          float: left;
          color: $dark;
          width: 100%;
          padding: 5px 15px;
          font-size: 2.5rem;
          line-height: 3.5rem;

          @media (min-width: $lg) {
            width: auto;
            padding: 7px 10px;
            border-radius: 10px;
            font-size: 1.7rem;
            line-height: 2.7rem;
          }

          @media (min-width: $xl) {
            padding: 7px 10px;
          }

          @media (min-width: $xxl) {
            padding: 10px 19px;
          }

          &:hover,
          &.active {
            color: $primary;

            .dropdown-arv {
              border-color: $primary;
            }
          }
        }

        &.current-menu-item a,
        &.current-menu-parent>a {
          color: $primary;
          font-weight: $bold;

          .dropdown-arv {
            border-color: $primary;
          }
        }

        .sub-menu {
          display: none;
          width: 100%;
          // padding-bottom: 10px;

          @media (min-width: $lg) {
            width: 240px;
            position: absolute;
            top: 100%;
            left: 0;
            background: $white;
            border-top: 2px solid $blue;
            padding: 10px 0;
            box-shadow: 0 2px 5px 0 rgba(0, 0, 0, 0.4);
          }

          &.active {
            @media (max-width: 991px) {
              display: block;
              float: left;
              width: 100%;
            }
          }

          .menu-item {
            margin: 0;

            a {
              color: $gray;
              width: 100%;
              padding: 3px 15px;
              font-weight: $normal;
              font-size: 1.6rem;
              line-height: 2.2rem;

              @media (min-width: $lg) {
                padding: 5px 15px;
              }

              &:hover {
                color: $blue;
                background: transparent;
              }

              &:before {
                content: '';
                display: none;
                padding-right: 5px;

                @media (max-width: 991px) {
                  display: inline-block;
                }
              }
            }

            &.current-menu-item a {
              color: $blue;
              background: transparent;
            }
          }
        }

        &:hover {
          .sub-menu {
            @media (min-width: $lg) {
              display: block;
            }
          }
        }

        &-has-children {
          // display: flex;
          // justify-content: center;

          a {
            // display: inline-block;
            // width: auto;
          }
        }
      }
    }
  }

  &__nav-col {
    display: flex;
    justify-content: flex-end;
    align-items: center;
  }
}

body {

  &.home {
    .main-wrapper {
      padding-top: 0;
    }
  }

  .main-wrapper {
    padding-top: 8rem;

    @media (min-width:$lg) {
      padding-top: 12rem;
    }
  }
}
import $ from 'jquery';

class Header {
	constructor(element) {
		this.$element = $(element);
		this.$burger = this.$element.find('.header__burger');
		this.$Nav = this.$element.find('.nav-main');
		this.$hasSub = this.$element.find('.menu-item-has-children');
		this.$menuArrow = this.$element.find('.dropdown-arv-cont');
		this.$menuBg = this.$element.find('.header__menu-bg');
		this.init();
	}

	// headerPadding() {
	// 	if (!this.$element.hasClass('header--transperant')) {
	// 		let hHeight = this.$element.height();
	// 		$('.main-wrapper').css({ 'padding-top': hHeight });
	// 	}
	// }

	init() {
		// $(document).ready(() => {
		// 	this.headerPadding();
		// });

		$(window).on('resize load', () => {
			this.$element.addClass('loaded');
		});

		$(window).on('scroll', () => {
			if ($(window).scrollTop() > 100) {
				$('.header').addClass('sticky');
			} else {
				$('.header').removeClass('sticky');
			}
		});

		$(document).on(
			'click',
			'.menu-item-has-children .dropdown-arv-cont',
			function () {
				$(this).closest('li').toggleClass('active');
			},
		);

		this.$burger.on('click', (e) => {
			e.preventDefault();
			if ($(e.currentTarget).hasClass('opened')) {
				$(e.currentTarget).removeClass('opened').attr('aria-expanded', 'false');
				this.$Nav.slideUp(300).parent().removeClass('active');
				$('.menu-item-has-children .dropdown-arv-cont').removeClass('active');
				$('body').css('overflow-y', 'visible');
				$('.dropdown-arv-cont')
					.closest('li')
					.children('.sub-menu')
					.removeClass('active');
			} else {
				$(e.currentTarget).addClass('opened').attr('aria-expanded', 'true');
				this.$Nav.slideDown(300).parent().toggleClass('active');
				$('body').css('overflow-y', 'hidden');
			}
		});

		this.$menuBg.on('click', (e) => {
			e.preventDefault();
			this.$burger.removeClass('opened').attr('aria-expanded', 'false');
			this.$Nav.slideUp(300).parent().removeClass('active');
		});

		$(document).on('click', '.dropdown-arv-cont', function (e) {
			e.preventDefault();
			if ($(this).hasClass('active')) {
				$(this).removeClass('active');
				$(this).closest('li').children('.sub-menu').removeClass('active');
			} else {
				$(this).addClass('active');
				$(this).closest('li').children('.sub-menu').addClass('active');
			}
		});
	}
}

$('[data-header]').each((index, element) => new Header(element));
version: '3.9'

services:
  prometheus:
    image: prom/prometheus:latest
    container_name: prometheus
    hostname: prometheus
    command:
      - '--config.file=/etc/prometheus/prometheus.yml'
    ports:
      - 9090:9090
    stdin_open: true
    tty: true
    restart: always
    environment:
      TZ: "Europe/Moscow"
    volumes:
      - ./prometheus/:/etc/prometheus/
      - prom_data:/prometheus
    networks:
     default:
      ipv4_address: 172.28.0.101
  grafana:
    image: grafana/grafana
    container_name: grafana
    ports:
      - 3000:3000
    stdin_open: true
    tty: true
    restart: always
    environment:
      - GF_SECURITY_ADMIN_USER=admin
      - GF_SECURITY_ADMIN_PASSWORD=grafana
    volumes:
      - ./grafana:/etc/grafana/provisioning/datasources
    links:
      - prometheus
    networks:
     default:
      ipv4_address: 172.28.0.102
  node_exporter:
    image: prom/node-exporter
    container_name: exporter
    hostname: exporter
    command:
      - --path.procfs=/host/proc
      - --path.sysfs=/host/sys
      - --collector.filesystem.ignored-mount-points
      - ^/(sys|proc|dev|host|etc|rootfs/var/lib/docker/containers|rootfs/var/lib/docker/overlay2|rootfs/run/docker/netns|rootfs/var/lib/docker/aufs)($$|/)
    pid: host
    environment:
      TZ: "Europe/Moscow"
    restart: always
    volumes:
      - /proc:/host/proc:ro
      - /sys:/host/sys:ro
      - /:/rootfs:ro
    ports:
      - "9100:9100"
    networks:
     default:
      ipv4_address: 172.28.0.103
  alertmanager:
    image: prom/alertmanager:latest
    container_name: alertmanager
    hostname: alertmanager
    ports:
      - 9093:9093
    volumes:
      - ./alertmanager/:/etc/alertmanager/
      - alertmanager-data:/data
    restart: always
    command:
      - '--config.file=/etc/alertmanager/alertmanager.yml'
      - '--storage.path=/alertmanager'
    networks:
     default:
      ipv4_address: 172.28.0.104
networks:
  default:
    ipam:
      driver: default
      config:
        - subnet: 172.28.0.0/16
volumes:
  prom_data:
  alertmanager-data:
Basics
Print a number	print(123)
Print a string	print("test")
Adding numbers	print(1+2)
Variable assignment	number = 123
Print a variable	print(number)
Function call	x = min(1, 2)
Comment	# a comment
Types
Integer	42
String	"a string"
List	[1, 2, 3]
Tuple	(1, 2, 3)
Boolean	True
Useful functions
Write to the screen	print("hi")
Calculate length	len("test")
Minimum of numbers	min(1, 2)
Maximum of numbers	max(1, 2)
Cast to integer	int("123")
Cast to string	str(123)
Cast to boolean	bool(1)
Range of numbers	range(5, 10)
Other syntax
Return a value	return 123
Indexing	"test"[0]
Slicing	"test"[1:3]
Continue to next loop iteration	continue
Exit the loop	break
List append	numbers = numbers + [4]
List append (with method call)	numbers.append(4)
List item extraction	value = numbers[0]
List item assignment	numbers[0] = 123
Terminology
syntax	the arrangement of letters and symbols in code
program	a series of instructions for the computer
print	write text to the screen
string	a sequence of letters surrounded by quotes
variable	a storage space for values
value	examples: a string, an integer, a boolean
assignment	using = to put a value into a variable
function	a machine you put values into and values come out
call (a function)	to run the code of the function
argument	the input to a function call
parameter	the input to a function definition
return value	the value that is sent out of a function
conditional	an instruction that's only run if a condition holds
loop	a way to repeatedly run instructions
list	a type of value that holds other values
tuple	like a list, but cannot be changed
indexing	extracting one element at a certain position
slicing	extracting some elements in a row
dictionary	a mapping from keys to values
Reminders
Strings and lists are indexed starting at 0, not 1
Print and return are not the same concept
The return keyword is only valid inside functions
Strings must be surrounded by quotes
You cannot put spaces in variable or function names
You cannot add strings and integers without casting
Consistent indentation matters
Use a colon when writing conditionals, function definitions, and loops
Descriptive variable names help you understand your code better
Conditionals
if x == 1:
	print("x is one")
else:
	print("x is not one") 

Copy and Save

Share

Ask Copilot

 Save
Lists
numbers = [7, 8, 9]
first_number = numbers[0]
numbers[2] = 11
if 11 in numbers:
	print("11 is in the list!")
for n in numbers:
	print(n) 

Copy And Save

Share

Ask Copilot

 Save
Defining functions
def my_func (param1, param2):
	result = param1 + param2
	return result 

Copy And Save

Share

Ask Copilot

 Save
Loops
for number in [1, 2, 3]:
	print(number)

x = 0
while x < 10:
	print(x)
	x = x + 1 

Copy And Save

Share

Ask Copilot

 Save
Dictionaries
numbers = {
	1: "one",
	2: "two"
}

print(numbers[1]) 

Copy And Save

Share

Ask Copilot

 Save
Comparisons
Equals	==
Not equals	!=
Less than	<
Less than or equal	<=
Greater than	>
Useful methods
String to lowercase	"xx".lower()
String to uppercase	"xx".upper()
Split string by spaces	"a b c".split(" ")
Remove whitespace around string	" a string ".strip()
Combine strings into one string	" ".join(["a", "b"])
String starts with	"xx".startswith("x")
String ends with	"xx".endswith("x")
List count	[1, 2].count(2)
List remove	[1, 2].remove(2)
Dictionary keys	{1: 2}.keys()
Dictionary values	{1: 2}.values()
Dictionary key/value pairs	{1: 2}.items()
Other neat bonus stuff
Zip lists	zip([1, 2], ["one", "two"])
Set	my_set = {1, 2, 3}
Set intersection	{1, 2} & {2, 3}
Set union	{1, 2} | {2, 3}
Index of list element	[1, 2, 3].index(2)
Sort a list	numbers.sort()
Reverse a list	numbers.reverse()
Sum of list	sum([1, 2, 3])
Numbering of list elements	for i, item in enumerate(items):
Read a file line by line	for line in open("file.txt"):
Read file contents	contents = open("file.txt").read()
Random number between 1 and 10	import random; x = random.randint(1, 10)
List comprehensions	[x+1 for x in numbers]
Check if any condition holds	any([True, False])
Check if all conditions hold	all([True, False])
function countdown(value)
  if value is negative or zero
    print "done"
  otherwise if value is greater than zero
    print value
    call countdown with (value-1)
var contentSlider = $('.blog-slider__cont');
		var imageSlider = $('.blog-slider__slider');

		contentSlider.owlCarousel({
			items: 1,
			loop: true,
			dots: false,
			nav: false,
			mouseDrag: false,
			touchDrag: false,
		});

		imageSlider.owlCarousel({
			loop: true,
			dots: true,
			nav: false,
			items: 1,
			margin: 30,
			responsive: {
				320: {
					items: 1,
				},
				576: {
					items: 2,
				},
			},
		});

		imageSlider.on('changed.owl.carousel', function (event) {
			var currentIndex = event.relatedTarget.relative(event.item.index);
			contentSlider.trigger('to.owl.carousel', [currentIndex]);
		});
input[value="+"],
input[value="-"] {
	color: $primary;
}
//Without payload
export const moveRight = () => ({
	type: MOVE_RIGHT
});

//With payload
export const moveRight = (data: string) => ({
	type: MOVE_RIGHT,
	payload: data
});
function* performAction() {
    yield put({
        type: COPY_DATA,
        payload: "Hello"
    });
}
{% assign enter_date_of_birth = true %}

{% assign age = 18 %}

{% capture adult_header %}
Solo per adulti (18+)
{% endcapture %}

{% capture adult_text %}
  <p class="para">I contenuti di Boem sono riservati ad un pubblico maggiorenne.<br>Per favore verifica la tua età per accedere al sito.</p>
{% endcapture %}

{% capture birthdate %}
  <p>Inserisci la tua data di nascita</p>
{% endcapture %}

<div id="prompt-background">
  <div id="age-check-prompt" class="modal-prompt">
    <div class="col-12">          
      <div class="logo">
        <img src="{% comment %} logo qui {% endcomment %}" alt="{{ shop.name }}" style="max-width:100px;">
      </div>
    </div>
    <h1>
      {{ adult_header }}
    </h1>
    <p>
      {{ adult_text }}
    </p>
    <p>
      {{ birthdate }}
    </p>
    <p id="msg" style="display:none;">
      Devi avere più di 18 anni per poter accedere al sito
    </p>
    <div{% unless enter_date_of_birth %} style="display:none;"{% endunless %}>
      <select name="bmonth" id="bmonth"{% unless enter_date_of_birth %} value="1"{% endunless %}>
        {% if enter_date_of_birth %}
        <option value="1">- Mese -</option>
        <option value="1">Gennaio</option>
        <option value="2">Febbraio</option>
        <option value="3">Marzo</option>
        <option value="4">Aprile</option>
        <option value="5">Maggio</option>
        <option value="6">Giugno</option>
        <option value="7">Luglio</option>
        <option value="8">Agosto</option>
        <option value="9">Settembre</option>
        <option value="10">Ottobre</option>
        <option value="11">Novembre</option>
        <option value="12">Dicembre</option>
        {% endif %}
      </select> 
      <select name="bday" id="bday"{% unless enter_date_of_birth %} value="1"{% endunless %}>
        {% if enter_date_of_birth %}
        <option value="1">- Giorno -</option>
        <option value="1">1</option>
        <option value="2">2</option>
        <option value="3">3</option>
        <option value="4">4</option>
        <option value="5">5</option>
        <option value="6">6</option>
        <option value="7">7</option>
        <option value="8">8</option>
        <option value="9">9</option>
        <option value="10">10</option>
        <option value="11">11</option>
        <option value="12">12</option>
        <option value="13">13</option>
        <option value="14">14</option>
        <option value="15">15</option>
        <option value="16">16</option>
        <option value="17">17</option>
        <option value="18">18</option>
        <option value="19">19</option>
        <option value="20">20</option>
        <option value="21">21</option>
        <option value="22">22</option>
        <option value="23">23</option>
        <option value="24">24</option>
        <option value="25">25</option>
        <option value="26">26</option>
        <option value="27">27</option>
        <option value="28">28</option>
        <option value="29">29</option>
        <option value="30">30</option>
        <option value="31">31</option>
        {% endif %}
      </select>
      <select name="byear" id="byear"{% unless enter_date_of_birth %} value="1950"{% endunless %}>
        {% if enter_date_of_birth %}
        <option value="2015">- Anno -</option>
        <option value="2014">2014</option>
        <option value="2013">2013</option>
        <option value="2012">2012</option>
        <option value="2011">2011</option>
        <option value="2010">2010</option>
        <option value="2009">2009</option>
        <option value="2008">2008</option>
        <option value="2007">2007</option>
        <option value="2006">2006</option>
        <option value="2005">2005</option>
        <option value="2004">2004</option>
        <option value="2003">2003</option>
        <option value="2002">2002</option>
        <option value="2001">2001</option>
        <option value="2000">2000</option>
        <option value="1999">1999</option>
        <option value="1998">1998</option>
        <option value="1997">1997</option>
        <option value="1996">1996</option>
        <option value="1995">1995</option>
        <option value="1994">1994</option>
        <option value="1993">1993</option>
        <option value="1992">1992</option>
        <option value="1991">1991</option>
        <option value="1990">1990</option>
        <option value="1989">1989</option>
        <option value="1988">1988</option>
        <option value="1987">1987</option>
        <option value="1986">1986</option>
        <option value="1985">1985</option>
        <option value="1984">1984</option>
        <option value="1983">1983</option>
        <option value="1982">1982</option>
        <option value="1981">1981</option>
        <option value="1980">1980</option>
        <option value="1979">1979</option>
        <option value="1978">1978</option>
        <option value="1977">1977</option>
        <option value="1976">1976</option>
        <option value="1975">1975</option>
        <option value="1974">1974</option>
        <option value="1973">1973</option>
        <option value="1972">1972</option>
        <option value="1971">1971</option>
        <option value="1970">1970</option>
        <option value="1969">1969</option>
        <option value="1968">1968</option>
        <option value="1967">1967</option>
        <option value="1966">1966</option>
        <option value="1965">1965</option>
        <option value="1964">1964</option>
        <option value="1963">1963</option>
        <option value="1962">1962</option>
        <option value="1961">1961</option>
        <option value="1960">1960</option>
        <option value="1959">1959</option>
        <option value="1958">1958</option>
        <option value="1957">1957</option>
        <option value="1956">1956</option>
        <option value="1955">1955</option>
        <option value="1954">1954</option>
        <option value="1953">1953</option>
        <option value="1952">1952</option>
        <option value="1951">1951</option>
        <option value="1950">1950</option>
        <option value="1949">1949</option>
        <option value="1948">1948</option>
        <option value="1947">1947</option>
        <option value="1946">1946</option>
        <option value="1945">1945</option>
        <option value="1944">1944</option>
        <option value="1943">1943</option>
        <option value="1942">1942</option>
        <option value="1941">1941</option>
        <option value="1940">1940</option>
        <option value="1939">1939</option>
        <option value="1938">1938</option>
        <option value="1937">1937</option>
        <option value="1936">1936</option>
        <option value="1935">1935</option>
        <option value="1934">1934</option>
        <option value="1933">1933</option>
        <option value="1932">1932</option>
        <option value="1931">1931</option>
        <option value="1930">1930</option>
        <option value="1929">1929</option>
        <option value="1928">1928</option>
        <option value="1927">1927</option>
        <option value="1926">1926</option>
        <option value="1925">1925</option>
        <option value="1924">1924</option>
        <option value="1923">1923</option>
        <option value="1922">1922</option>
        <option value="1921">1921</option>
        <option value="1920">1920</option>
        <option value="1919">1919</option>
        <option value="1918">1918</option>
        <option value="1917">1917</option>
        <option value="1916">1916</option>
        <option value="1915">1915</option>
        <option value="1914">1914</option>
        <option value="1913">1913</option>
        <option value="1912">1912</option>
        <option value="1911">1911</option>
        <option value="1910">1910</option>
      {% endif %}
      </select>
      <div style="clear:both; margin-bottom:15px"></div>
    </div>
    <div class="buttons_wrapper">
      <button id="submit_birthdate" class="button-enter btn styled-submit confirm" onclick="ageCheck()" style="display:inline-block">Entra</button> 
      <span style="padding: 0 6px">o</span>
      <a href="http://google.com/" id="button-exit" class="reject" name="button-exit">Esci</a>
    </div>
  </div>
</div>

<script>
 function ageCheck() {
   var min_age = {{ age }};  // Set the minimum age. 
   var year =   parseInt(document.getElementById('byear').value);
   var month =  parseInt(document.getElementById('bmonth').value);
   var day =    parseInt(document.getElementById('bday').value);
   var msg = document.getElementById('msg');
   var theirDate = new Date((year + min_age), month, day);
   var today = new Date;
   if ((today.getTime() - theirDate.getTime()) < 0) {
     // window.location = 'http://google.com';
     msg.style.display = 'block';
   } else {
     var days = 14; //number of days until they must go through the age checker again.
     var date = new Date();
     date.setTime(date.getTime()+(days*24*60*60*1000));
     var expires = "; expires="+date.toGMTString();
     document.cookie = 'isAnAdult=true;'+expires+"; path=/";
     location.reload();
   };
  };

  function readCookie(name) {
    var nameEQ = name + "=";
    var ca = document.cookie.split(';');
    for(var i=0;i < ca.length;i++) {
      var c = ca[i];
      while (c.charAt(0)==' ') c = c.substring(1,c.length);
      if (c.indexOf(nameEQ) == 0) return c.substring(nameEQ.length,c.length);
    }
    return null;
  };

  var isAnAdult = readCookie('isAnAdult');
  if (isAnAdult) {
    document.write("<style> #prompt-background { display: none; }</style>");
  };

</script>

<style>

.modal-prompt {
  background: #fff;
  border-radius: 2px;
  box-shadow: 0px 0px 10px rgba(0,0,0,0.5);
  width: 500px;
  height: auto;
  margin: 0 auto;
  padding: 20px 35px 30px 35px;
  position: relative;
  top: 25%;
  z-index: 1000000;
}

@media all and (max-width: 768px) {
  .modal-prompt {
    width: 330px;
  }  
}

.modal-prompt select {
  border: 1px solid #EEE; 
}

.modal-prompt select:not(:last-child){
  margin-bottom: 5px;
}

#age-check-prompt .buttons_wrapper {
  display: flex;
  align-items: baseline;
}

#age-check-prompt .buttons_wrapper a {
  padding: 6px 18px;
}

#age-check-prompt #msg {
  color: #721c24;
  background-color: #f8d7da;
  border-color: #f5c6cb;
  padding: 10px 18px;
  text-align: center;
}
  
.modal-prompt p, .modal-prompt h1 {
  color: #555555;
}

#prompt-background {
  background: url("{{ 'age-check-background.jpg' | asset_url }}") no-repeat center center fixed #555;
  -webkit-background-size: cover;
  -moz-background-size: cover;
  -o-background-size: cover;
  background-size: cover;
  width: 100%;
  height: 100%;
  position: fixed;
  left: 0;
  top: 0;
  z-index: 9999999;
}

#prompt-background .logo {
  text-align: center;
  margin-bottom: 15px;
}

#prompt-background .confirm {
  transition: all 0.3s linear;
  background-color: #28a745;
  color: #ffffff;
  border-radius: 0 !important;
}

#prompt-background .reject {
  transition: all 0.3s linear;
  background-color: #ea0028;
  color: #ffffff;
  border-radius: 0 !important;
}
  
.modal-prompt select { float: left; margin-right: 10px; }

</style>
// postcss.config.js
const { join } = require('path');

module.exports = {
  plugins: {
    tailwindcss: {
      config: join(__dirname, 'tailwind.config.js'),
    },
    autoprefixer: {},
  },
};
var $cont = document.querySelector(".cont");

var $elsArr = [].slice.call(document.querySelectorAll(".el"));

var $closeBtnsArr = [].slice.call(document.querySelectorAll(".el__close-btn"));

​

setTimeout(function () {

 $cont.classList.remove("s--inactive");

}, 0);

​

$elsArr.forEach(function ($el) {

 $el.addEventListener("click", function () {

  if (this.classList.contains("s--active")) return;

  $cont.classList.add("s--el-active");

  this.classList.add("s--active");

 });

});

​

$closeBtnsArr.forEach(function ($btn) {

 $btn.addEventListener("click", function (e) {

  e.stopPropagation();
20
  $cont.classList.remove("s--el-active");

  document.querySelector(".el.s--active").classList.remove("s--active");

 });

});
engine = db.create_engine('sqlite:///datacamp.sqlite')
conn = engine.connect()
metadata = db.MetaData()

Student = db.Table('Student', metadata,
              db.Column('Id', db.Integer(),primary_key=True),
              db.Column('Name', db.String(255), nullable=False),
              db.Column('Major', db.String(255), default="Math"),
              db.Column('Pass', db.Boolean(), default=True)
              )

metadata.create_all(engine)
from sqlalchemy import create_engine
engine = create_engine("sqlite+pysqlite:///:memory:", echo=True)

connection = engine.connect()
print("Connected to the database successfully")
connection.close()
class Solution:
    def insert(
        self, intervals: List[List[int]], newInterval: List[int]
    ) -> List[List[int]]:
        res = []

        for i in range(len(intervals)):
            if newInterval[1] < intervals[i][0]:
                res.append(newInterval)
                return res + intervals[i:]
            elif newInterval[0] > intervals[i][1]:
                res.append(intervals[i])
            else:
                newInterval = [
                    min(newInterval[0], intervals[i][0]),
                    max(newInterval[1], intervals[i][1]),
                ]
        res.append(newInterval)
        return res
.gelatine {
  animation: gelatine 0.5s infinite;
}
@keyframes gelatine {
  from, to { transform: scale(1, 1); }
  25% { transform: scale(0.9, 1.1); }
  50% { transform: scale(1.1, 0.9); }
  75% { transform: scale(0.95, 1.05); }
}
#include <stdio.h>

int main() {
    int a;
    int b;
    
    printf("Enter marks from part 1 :");
    scanf("%d",&a);
    
    printf("Enter marks from part 2: ");
    scanf("%d",&b);
    
    int totalMarks =(a+b)/2;
    printf("Total marks of the paper: %d\n",totalMarks);
    
if(totalMarks>=75){
        printf("Grade: A");
    }
    else if(totalMarks>=65){
        printf("Grade: B");
    }else if(totalMarks>=55){
        printf("Grade: C");
    }else if(totalMarks>=35){
        printf("Grade: S");
    }else{
        printf("fail");
    }
    return 0;
}
#include <stdio.h>

int main() {
    int a;
    int b;
    
    printf("Enter marks from part 1 :");
    scanf("%d",&a);
    
    printf("Enter marks from part 2: ");
    scanf("%d",&b);
    
    int totalMarks =(a+b)/2;
    printf("Total marks of the paper: %d\n",totalMarks);
    
if(totalMarks>=75){
        printf("Grade: A");
    }
    else if(totalMarks>=65){
        printf("Grade: B");
    }else if(totalMarks>=55){
        printf("Grade: C");
    }else if(totalMarks>=35){
        printf("Grade: S");
    }else{
        printf("fail");
    }
    return 0;
}
rm -rf ~/.cache/JetBrains/PyCharm2024.1/cythonExtensions
<p><span id="docs-internal-guid-6f29315e-7fff-b55c-15a8-27e737606363"> </span></p>
<p dir="ltr">&nbsp;</p>
<p dir="ltr"><a href="https://fubar.com/help-blogs/b361314-1318694"><span><span><img src="https://lh7-us.googleusercontent.com/Bhc96hvMZnMbG6LVt-xUg_HBnnNEl0OwZjCtiVKU7-VmeZKZJ8W1JjcobC6Ugm37BpKW4r62Vc4HEI1vfQ9a9eG54ehL-lPai42PtclP96-QJBvy-NatFkSg9Gah7UTX6PqCKAQEkE2yaWcDSQFbTY8" alt="" width="172" height="29" /></span></span></a><a href="https://fubar.com/quick-like-polish-list/b373141"><span><span><img src="https://lh7-us.googleusercontent.com/BfE_Vu-IoKQ8RMa0wSINl6AYJdUqP-U0y79v92_GXBkspSg9pd_-XX9O7ecwRJH0svXVpKcTbE9WJOLsmOUqo0L3fBfkn10U4lHrCAM__UVdJn2_XxkKDOpCk48ZoglHmcJrWvB8o9v-I0hboeZ5X6o" alt="" width="204" height="29" /></span></span></a><a href="https://fubar.com/help.php"><span><span><img src="https://lh7-us.googleusercontent.com/tahv4Cbm08xNSdjT88DwsJwqGaJvP1FoQSXRdoitfSe-Lw2Dd-5tk7Z7wLmyhOIiV_WqJuWSSlz_IZs2fEDnilHZ7oJ50-BPr_1GfptvEoRUrXVuUayxfmqt6CSUuIZPg0PBy5UtNOkR0FTi9JLekAs" alt="" width="178" height="29" /></span></span></a><a href="https://fubar.com/bible.php"><span><span><img src="https://lh7-us.googleusercontent.com/ndhbaL4t8eBeWvSKf5MT4V38ZydpPdAFBg-aNGykWF7FDzuk8fRfeKFs7w5j_lw4AcgHnp1nZzexyvJ0biiZSCcMKbZbGMFmSfNkM8MCTdOF9Spgk3zHV5ScxF7dKKnoK9vghf0y0pRwJct3aLYhyxk" alt="" width="127" height="29" /></span></span></a><a href="https://www.fubar.com/tos.php"><span><span><img src="https://lh7-us.googleusercontent.com/DJ7XJK7yGWWFgRE5fAFORSRWTYcMD970AEYWhnDntD_VKg2kAQLxIohvBy4k6oF89PDyKZPdGcermOxVCZ4Vzl8yrh9xaHirqSlM_wJPvqOKHY1lu32ZttzAghY1r2gsSHP0ApYZoQPQADLgpSWdEKI" alt="" width="118" height="29" /></span></span></a><a href="http://fubar.com/blast_list.php"><span><span><img src="https://lh7-us.googleusercontent.com/HZM1yiLSYZY5pDtWVKj1TBdeW6zuxu-Yo39mBzeNKjfUbXsrX5RKl6xkNk0ytyki5yWvw4NQrZzohiaONb8ODV9dotNn24VG8yczRg6rPqqJknjeQP7beVdEPSAWX3-cXJ8qGHdKK4tAsvQp6m2MeDs" alt="" width="136" height="29" /></span></span></a><a href="http://www.fubar.com/emotes.php"><span><span><img src="https://lh7-us.googleusercontent.com/XeuFUnLnXQVvZ3DwVcaK-XhtwUdX6NKANmrtWViAkaZF99W9cJIcH1YwzP-GVi_vLrlaC7rSUNLljWTN7CDfsLCNk3VoVkIdDGPY-JXYd1B0DQxwPunxKI1u5WlKSwbbgBwzK-jO7uK97md-e9RZDJU" alt="" width="144" height="29" /></span></span></a><a href="https://fubar.com/bling.php?sent=1"><span><span><img src="https://lh7-us.googleusercontent.com/e-Ba-qefqHZKcfEmKULRqlGCsxpUixeM4O4pkae274pMswwNKjLFb_eQA0Zld5rX79hLFLnqiLxQZSD8MEAvxFPfbp_2YcMWTRU2FhNrr3MLX4bRQhsC2HV5L5s9OMDT6RrkgdAXYZBJviedPehhem0" alt="" width="162" height="29" /></span></span></a><a href="http://fubar.com/marriage.php"><span><span><img src="https://lh7-us.googleusercontent.com/0eMylWECNNjDddeTztE3yWlJCAzw1BlJ6jB-vz0i4RYfodA-OiXlEKGFDeS9CPS4pezTtwP3m5H6F_N6fM_f4R40rEmKZvgMyqebKatwhSdlRqeX8r-KC7F7ZamGUvakcSXiMMjbDPDNIPohhN_FQ34" alt="" width="117" height="29" /></span></span></a><a href="https://fubarswag.myspreadshop.com/"><span><span><img src="https://lh7-us.googleusercontent.com/X4vRibtwdEnWz3fdLMJO1-4yCYkxJ6KnqdTPZi7-HWsz2N5h-oWytjcpOlhJc8kl92kTflWT1favNk6ACCQZPNYDf3cnQUWu1n_TrByN4xOdHh528kgax_McbgWntvF83faQItNCpiYIwW7C9n37rfM" alt="" width="127" height="29" /></span></span></a><a href="https://fubar.com/vip.php"><span><span><img src="https://lh7-us.googleusercontent.com/8PVUHAnW4XuMQkBmytMBxvwo8AIwAILhHZT3Q4Ayn9aJsZuh8e-l9zygyHlFT93I0wYgBJejGD9b5F5ew36d9T-BPmG6Ns4PPqHWLB7ktp37hAPOSxH_VRY5wtRNnGTltFmHviOWHcdGPIXmnObgmrg" alt="" width="98" height="29" /></span></span></a><a href="https://fubar.com/lounge/support"><span><span><img src="https://lh7-us.googleusercontent.com/79MRkP11vV5xspKJd0ooJ_dt7n3KXxUWjsoJleCAxCuBGcwPsgqGhiPMVPj5Pp9veNaKcuEiXL-tLu0GP0yZMfow5AeQGZW7DXuVKcuooltSP3wQY3BGf5kgY_772LUWSdryyOMMA1z0jt75lLQLjTg" alt="" width="207" height="29" /></span></span></a><a href="https://fubar.com/blogs.php?u=22"><span><span><img src="https://lh7-us.googleusercontent.com/i-fDHpQdS9yDffiVTmbVlLx70azD7_F2uRO4j4Fc6YSfhGXi6fb_iNBdjqxknsZCY-3wz12-l4Q2Z-hlitN0pcoV1SqVxbjMSIEEcp45Kzh4wcr9iAWBqRYbVh-lGNCEVhF9uBkmp7-DyYeXiUjkf1w" alt="" width="151" height="29" /></span></span></a></p>
<p>&nbsp;</p>
0 0.961847 0.151807 0.945783 0.151807 0.929719 0.166265 0.923695 0.180723 0.923695 0.207229 0.903614 0.243373 0.853414 0.26506 0.833333 0.279518 0.799197 0.289157 0.787149 0.289157 0.783133 0.284337 0.781124 0.255422 0.7751 0.243373 0.773092 0.166265 0.76506 0.151807 0.746988 0.159036 0.692771 0.207229 0.668675 0.209639 0.654618 0.216867 0.620482 0.216867 0.592369 0.207229 0.574297 0.207229 0.568273 0.214458 0.568273 0.240964 0.580321 0.26747 0.580321 0.279518 0.568273 0.296386 0.554217 0.344578 0.53012 0.383133 0.502008 0.414458 0.447791 0.513253 0.413655 0.595181 0.385542 0.689157 0.373494 0.780723 0.383534 0.807229 0.381526 0.850602 0.395582 0.872289 0.437751 0.891566 0.475904 0.901205 0.516064 0.903614 0.556225 0.915663 0.588353 0.908434 0.594378 0.889157 0.586345 0.860241 0.616466 0.824096 0.630522 0.79759 0.648594 0.742169 0.648594 0.689157 0.65261 0.684337 0.662651 0.693976 0.668675 0.739759 0.676707 0.761446 0.686747 0.773494 0.712851 0.778313 0.722892 0.766265 0.728916 0.744578 0.722892 0.66747 0.708835 0.631325 0.680723 0.60241 0.688755 0.566265 0.710843 0.53494 0.730924 0.46506 0.746988 0.440964 0.787149 0.404819 0.821285 0.392771 0.85743 0.366265 0.893574 0.325301 0.953815 0.26988 0.96988 0.209639 0.96988 0.168675
coco/
└── annotations/
    └── coco_annotations.json
coco_to_yolo.py
coco_converted/
├── images/
└── labels/
    └── coco_annotations/
        └── image1.txt
        └── image2.txt
python coco_to_yolo.py
.\venv\Scripts\activate.ps1
#include <stdlib.h>
#include <stdio.h>
#include <time.h>
 
typedef struct
{
    char **arr;
    int size;
} Arr;
 
typedef struct
{
    char *Name;
    int Count;
    float Rating;
} Product;
 
Arr input(FILE *f);
 
int main(void)
{
    Arr nouns;
    Arr adj;
 
    Product pr1;
 
    FILE *fn;
    FILE *fa;
    FILE *out;
 
    char *name;
    int i;
    int j;
    int n;
    int a;
 
    srand(time(NULL));
 
    fn = fopen("noun.txt", "r");
 
    if (fn == NULL)
    {
        printf("Error openning file");
        return 1;
    }
 
    fa = fopen("adj.txt", "r");
    
    if(fa == NULL)
    {
        printf("Error openning file");
        fclose(fn);
        return 1;
    }
 
    out = fopen("output.txt", "w");
 
    if(fgetc(fn) == EOF || fgetc(fa) == EOF)
    {
        fclose(fn);
        fclose(fa);
        fclose(out);
        printf("file is empty!");
        return 1;
    }
    else
    {
        fseek(fn, 0, SEEK_SET);
        fseek(fa, 0, SEEK_SET);
    }
 
    nouns = input(fn);
    adj = input(fa);
 
    n = rand() % nouns.size;
    a = rand() % adj.size;
 
    pr1.Count = rand() % 100;
    pr1.Rating = (float)(rand() % 100) / 10.0; // Generating a float rating between 0 and 10
 
    name = malloc(sizeof(char));
 
    i = 0;
    j = 0;
 
    while (1)
    {
        if (adj.arr[a][i] != '\0')
        {
            name = realloc(name, sizeof(char) * (i + 1));
            name[i] = adj.arr[a][i];
            i++;
        }
        else
        {
            name = realloc(name, sizeof(char) * (i + 1));
            name[i] = ' ';
            i++;
            break;
        }
    }
 
    while (1)
    {
        if (nouns.arr[n][j] != '\0')
        {
            name = realloc(name, sizeof(char) * (i + 1));
            name[i] = nouns.arr[n][j];
            i++;
            j++;
        }
        else
        {
            name = realloc(name, sizeof(char) * (i + 1));
            name[i] = '\0';
            break;
        }
    }
    pr1.Name = name;
 
    fprintf(out, "%s %d %.1f", pr1.Name, pr1.Count, pr1.Rating);
 
    free(name);
    for (int k = 0; k < nouns.size; k++)
    {
        free(nouns.arr[k]);
    }
    for (int k = 0; k < adj.size; k++)
    {
        free(adj.arr[k]);
    }
    free(nouns.arr);
    free(adj.arr);
 
    fclose(fn);
    fclose(fa);
    fclose(out);
 
    return 0;
}
 
Arr input(FILE *f)
{
    char **arr;
    char r;
    int size_w = 0;
    int count_w = 0;
 
    arr = malloc(sizeof(char *));
    arr[0] = malloc(sizeof(char));
 
    while ((r = fgetc(f)) != EOF)
    {
        if (r != '\0' && r != ' ')
        {
            if (r == '\n')
            {
                arr[count_w] = realloc(arr[count_w], (size_w + 1) * sizeof(char));
                arr[count_w][size_w] = '\0';
                count_w += 1;
                arr = realloc(arr, (count_w + 1) * sizeof(char *));
                arr[count_w] = malloc(sizeof(char));
                size_w = 0;
            }
            else
            {
                arr[count_w] = realloc(arr[count_w], (size_w + 1) * sizeof(char));
                arr[count_w][size_w] = r;
                size_w += 1;
            }
        }
    }
    count_w++;
    return (Arr){arr, count_w};
}
cd path\to\your\project\directory
coco/
└── annotations/
    └── coco_annotations.json
coco_to_yolo.py
from ultralytics.data.converter import convert_coco
convert_coco(labels_dir='annotations', use_segments=True)
coco/
└── annotations/
    └── coco_annotations.json
 {
      "id": 9,
      "width": 359,
      "height": 269,
      "file_name": "dog.4121.jpg",
      "license": 0,
      "flickr_url": "",
      "coco_url": "",
      "date_captured": 0
    },
    {
      "id": 10,
      "width": 200,
      "height": 297,
      "file_name": "dog.4123.jpg",
      "license": 0,
      "flickr_url": "",
      "coco_url": "",
      "date_captured": 0
    }
  ],
  "annotations": [
    {
      "id": 1,
      "image_id": 1,
      "category_id": 1,
      "segmentation": [
        [
          479.0, 63.0, 471.0, 63.0, 463.0, 69.0, 460.0, 75.0, 460.0, 86.0,
          450.0, 101.0, 425.0, 110.0, 415.0, 116.0, 398.0, 120.0, 392.0, 120.0,
          390.0, 118.0, 389.0, 106.0, 386.0, 101.0, 385.0, 69.0, 381.0, 63.0,
          372.0, 66.0, 345.0, 86.0, 333.0, 87.0, 326.0, 90.0, 309.0, 90.0,
          295.0, 86.0, 286.0, 86.0, 283.0, 89.0, 283.0, 100.0, 289.0, 111.0,
          289.0, 116.0, 283.0, 123.0, 276.0, 143.0, 264.0, 159.0, 250.0, 172.0,
          223.0, 213.0, 206.0, 247.0, 192.0, 286.0, 186.0, 324.0, 191.0, 335.0,
          190.0, 353.0, 197.0, 362.0, 218.0, 370.0, 237.0, 374.0, 257.0, 375.0,
          277.0, 380.0, 293.0, 377.0, 296.0, 369.0, 292.0, 357.0, 307.0, 342.0,
          314.0, 331.0, 323.0, 308.0, 323.0, 286.0, 325.0, 284.0, 330.0, 288.0,
          333.0, 307.0, 337.0, 316.0, 342.0, 321.0, 355.0, 323.0, 360.0, 318.0,
          363.0, 309.0, 360.0, 277.0, 353.0, 262.0, 339.0, 250.0, 343.0, 235.0,
          354.0, 222.0, 364.0, 193.0, 372.0, 183.0, 392.0, 168.0, 409.0, 163.0,
          427.0, 152.0, 445.0, 135.0, 475.0, 112.0, 483.0, 87.0, 483.0, 70.0
        ]
      ],
var xmlResponse = '<?xml version="1.0" encoding="UTF-8"?> <data code="0" name="piece-shipment-list" request-id="f1fc982b-fd81-4b63-92ae-eb60d1dd9262"> <data airway-bill-number="" delivery-event-flag="1" dest-country="DE" division="DPEED" domestic-id="" error-status="0" event-country="DE" event-location="" ice="DLVRD" identifier-type="2" international-flag="0" leitcode="" matchcode="" name="piece-shipment" order-preferred-delivery-day="false" origin-country="DE" pan-recipient-address="Heinrich-Brüning-Str. 7 53113 Bonn" pan-recipient-city="53113 Bonn" pan-recipient-name="Deutsche Post DHL" pan-recipient-postalcode="53113" pan-recipient-street="Heinrich-Brüning-Str. 7" piece-code="00340434161094022115" piece-customer-reference="" piece-id="8e464a3e-219a-459b-823b-07d9d92732e3" piece-identifier="340434161094022115" product-code="00" product-key="" product-name="DHL PAKET (parcel)" pslz-nr="5066934803" recipient-city="53113 Bonn" recipient-id="5" recipient-id-text="different person present" recipient-name="Kraemer" recipient-street="Heinrich-Brüning-Str. 7" ric="OTHER" routing-code-ean="" ruecksendung="false" searched-piece-code="00340434161094022115" searched-ref-no="" shipment-code="" shipment-customer-reference="" shipment-height="0.0" shipment-length="0.0" shipment-weight="0.0" shipment-width="0.0" shipper-address="" shipper-city="" shipper-name="No sender data has been transferred to DHL." shipper-street="" short-status="Delivery successful" standard-event-code="ZU" status="The shipment has been successfully delivered" status-liste="0" status-timestamp="18.03.2016 10:02" upu=""> <data _build-time="2017-01-14 19:56:42.000775" leitcode="5311304400700" name="piece-event-list" order-preferred-delivery-day="false" piece-id="8e464a3e-219a-459b-823b-07d9d92732e3" piece-identifier="340434161094022115" pslz-nr="5066934803" routing-code-ean="" ruecksendung="false"> <data event-country="Germany" event-location="Bremen" event-short-status="Posting at PACKSTATION" event-status="The shipment has been posted by the sender at the PACKSTATION" event-text="The shipment has been posted by the sender at the PACKSTATION" event-timestamp="17.03.2016 11:43" ice="SHRCU" name="piece-event" ric="PCKST" ruecksendung="false" standard-event-code="ES" /> <data event-country="Germany" event-location="Bremen" event-short-status="Transportation to parcel center of origin" event-status="The shipment has been taken from the PACKSTATION for onward transportation" event-text="The shipment has been taken from the PACKSTATION for onward transportation" event-timestamp="17.03.2016 13:53" ice="LDTMV" name="piece-event" ric="MVMTV" ruecksendung="false" standard-event-code="AA" /> <data event-country="Germany" event-location="" event-short-status="Pick-up successful" event-status="The shipment has been picked up" event-text="The shipment has been picked up" event-timestamp="17.03.2016 13:55" ice="PCKDU" name="piece-event" ric="PUBCR" ruecksendung="false" standard-event-code="AE" /> <data event-country="Germany" event-location="Bremen" event-short-status="Parcel center of origin" event-status="The shipment has been processed in the parcel center of origin" event-text="The shipment has been processed in the parcel center of origin" event-timestamp="17.03.2016 15:49" ice="LDTMV" name="piece-event" ric="MVMTV" ruecksendung="false" standard-event-code="AA" /> <data event-country="Germany" event-location="Neuwied" event-short-status="Destination parcel center" event-status="The shipment has been processed in the destination parcel center" event-text="The shipment has been processed in the destination parcel center" event-timestamp="18.03.2016 03:35" ice="ULFMV" name="piece-event" ric="UNLDD" ruecksendung="false" standard-event-code="EE" /> <data event-country="" event-location="" event-short-status="In delivery" event-status="The shipment has been loaded onto the delivery vehicle" event-text="The shipment has been loaded onto the delivery vehicle" event-timestamp="18.03.2016 09:00" ice="SRTED" name="piece-event" ric="NRQRD" ruecksendung="false" standard-event-code="PO" /> <data event-country="Germany" event-location="Bonn" event-short-status="Delivery successful" event-status="The shipment has been successfully delivered" event-text="The shipment has been successfully delivered" event-timestamp="18.03.2016 10:02" ice="DLVRD" name="piece-event" ric="OTHER" ruecksendung="false" standard-event-code="ZU" /> </data> </data> </data>';

// Parse the XML response
var parser = new XMLDocument2();
parser.parseXML(xmlResponse);

// Get the value of the "short-status" attribute from the <data> element
var shortStatus = parser.getNode('/data/data').getAttribute('short-status');;

// Print the value of the "short-status" attribute
gs.info("Short Status: " + shortStatus);
import React from 'react'
import { CardElement, Elements, StripeProvider } from '@stripe/react-stripe-js'
import { loadStripe } from '@stripe/stripe-js'

const stripePromise = loadStripe('<YOUR_STRIPE_PUBLISHABLE_KEY>')

const PaymentForm = () => {
  return (
    <CardElement />
  )
}

const App = () => {
  return (
    <StripeProvider stripe={stripePromise}>
      <Elements>
        <PaymentForm />
      </Elements>
    </StripeProvider>
  )
}

export default App
get 
app.get('/products', (req, res) => {
  const products = [
    {
      id: 1,
      name: 'Furniture 1',
      price: 1000,
      size: 'L',
      fabricTexture: 'Smooth',
      woodTexture: 'Polished',
      woodType: 'Oak',
      fabricType: 'Cotton',
    },
    // ... more products
  ];

  res.send(products);
});

post
app.post('/products', (req, res) => {
  const newProduct = {
    id: Date.now(),
    name: req.body.name,
    price: req.body.price,
    size: req.body.size,
    fabricTexture: req.body.fabricTexture,
    woodTexture: req.body.woodTexture,
    woodType: req.body.woodType,
    fabricType: req.body.fabricType,
  };

  const products = [
    {
      id: 1,
      name: 'Furniture 1',
      price: 1000,
      size: 'L',
      fabricTexture: 'Smooth',
      woodTexture: 'Polished',
      woodType: 'Oak',
      fabricType: 'Cotton',
    },
    // ... more products
  ];

  products.push(newProduct);

  res.send(newProduct);
});

get by id 
app.get('/products/:id', (req, res) => {
  const products = [
    {
      id: 1,
      name: 'Furniture 1',
      price: 1000,
      size: 'L',
      fabricTexture: 'Smooth',
      woodTexture: 'Polished',
      woodType: 'Oak',
      fabricType: 'Cotton',
    },
    // ... more products
  ];

  const product = products.find((p) => p.id === parseInt(req.params.id));

  if (!product) {
    return res.status(404).send({ error: 'Product not found' });
  }

  res.send(product);
});

put
app.put('/products/:id', (req, res) => {
  const products = [
    {
      id: 1,
      name: 'Furniture 1',
      price: 1000,
      size: 'L',
      fabricTexture: 'Smooth',
      woodTexture: 'Polished',
      woodType: 'Oak',
      fabricType: 'Cotton',
      updated: false,
    },
    // ... more products
  ];

  const product = products.find((p) => p.id === parseInt(req.params.id));

  if (!product) {
    return res.status(404).send({ error: 'Product not found' });
  }

  product.name = req.body.name || product.name;
  product.price = req.body.price || product.price;
  product.size = req.body.size || product.size;
  product.fabricTexture = req.body.fabricTexture || product.fabricTexture;
  product.woodTexture = req.body.woodTexture || product.woodTexture;
  product.woodType = req.body.woodType || product.woodType;
  product.fabricType = req.body.fabricType || product.fabricType;

  res.send(product);
});
---------------------------------------------------------------------------------------------------
https://www.slideshare.net/AvinashKumar896/a-seminar-report-on-artificial-intelligence
---------------------------------------------------------------------------------------------------
https://www.slideshare.net/sachinkumar831/sophia-robot
---------------------------------------------------------------------------------------------------
  
green comuting --> 
 
  https://blogs.nvidia.com/blog/what-is-green-computing/#:~:text=Green%20computing%2C%20or%20sustainable%20computing,software%20are%20designed%20and%20used.
---------------------------------------------------------------------------------------------------
  
// Online C compiler to run C program online
#include <stdio.h>

int main() {
    int a;
    int b;
    
    printf("Enter marks from part 1 :");
    scanf("%d",&a);
    
    printf("Enter marks from part 2: ");
    scanf("%d",&b);
    
    int totalMarks =(a+b)/2;
    printf("Total marks of the paper: %d\n",totalMarks);
    
if(totalMarks>=75){
        printf("Grade: A");
    }
    else if(totalMarks>=65){
        printf("Grade: B");
    }else if(totalMarks>=55){
        printf("Grade: C");
    }else if(totalMarks>=35){
        printf("Grade: S");
    }else{
        printf("fail");
    }
    return 0 ;
}
# Remove break line in sequences
awk '/^>/ { print (NR==1 ? "" : RS) $0; next } { printf "%s", $0 } END { printf RS }' input.fa > output.fa
// Assuming you have a model for the table you want to insert into
$model = new YourModel;
$model->packages = json_encode(request('packages')); // Store the selected packages as a JSON array
$model->save();


===================
  $packages = json_decode($model->packages);
#include<stdio.h>
int main(){
     int a;
     int b;
     
     
     printf("Enter number for a:");
     scanf("%d",&a);
     
     printf("Enter number for b:");
     scanf("%d",&b);
     
     int value = a+b;
     printf("The value is: %d\n",value);
    
    
    
    return 0;
}
#include<stdio.h>
int main(){
    
    int item1Code;
    printf("Enter item 01 code:");
    scanf("%d",&item1Code);
    
    int item1Name;
    printf("Enter item 01 name:");
    scanf("%s",&item1Name);

    int item1Price;
    printf("Enter item 01 price:");
    scanf("%d",&item1Price);
    
    int item2Code;
    printf("\nEnter item 02 code:");
    scanf("%d",&item2Code);
    
    int item2Name;
    printf("Enter item 02 name:");
    scanf("%s",&item2Name);

    int item2Price;
    printf("Enter item 02 price:");
    scanf("%d",&item2Price);
    
    int item3Code;
    printf("\nEnter item 03 code:");
    scanf("%d",&item3Code);
    
    int item3Name;
    printf("Enter item 03 name:");
    scanf("%s",&item3Name);

    int item3Price;
    printf("Enter item 03 price:");
    scanf("%d",&item3Price);
    
    int totalValue = (item1Price+item2Price+item3Price);
    printf("\nTotal price = %d\n",totalValue);
    
    
    printf("Inventory list:\n");
    printf("01.%d\n",item1Code);
    printf("02.%d\n",item2Code);
    printf("03.%d\n",item3Code);
    
    
    
    return 0;
}
<div class="enhanceable_content tabs" title="ingesloten inhoud">
    <ul style="list-style-type: none; padding: 0; margin: 0;">
        <li style="display: inline-block; background-color: red; padding: 10px 20px; border-radius: 10px;"><a style="text-decoration: none; color: white; font-family: 'Arial', sans-serif;" href="#fragment-1">Tabblad 1</a></li>
        <li style="display: inline-block; background-color: red; padding: 10px 20px; border-radius: 10px;"><a style="text-decoration: none; color: white; font-family: 'Arial', sans-serif;" href="#fragment-2">Tabblad 2</a></li>
        <li style="display: inline-block; background-color: red; padding: 10px 20px; border-radius: 10px;"><a style="text-decoration: none; color: white; font-family: 'Arial', sans-serif;" href="#fragment-3">Tabblad 3</a></li>
        <li style="display: inline-block; background-color: red; padding: 10px 20px; border-radius: 10px;"><a style="text-decoration: none; color: white; font-family: 'Arial', sans-serif;" href="#fragment-4">Tabblad 4</a></li>
        <li style="display: inline-block; background-color: red; padding: 10px 20px; border-radius: 10px;"><a style="text-decoration: none; color: white; font-family: 'Arial', sans-serif;" href="#fragment-5">Tabblad 5</a></li>
    </ul>
    <div id="fragment-1">
        <p>INHOUD 1</p>
    </div>
    <div id="fragment-2">
        <p>INHOUD 2</p>
    </div>
    <div id="fragment-3">
        <p>INHOUD 3</p>
    </div>
    <div id="fragment-4">
        <p>INHOUD 4</p>
    </div>
    <div id="fragment-5">
        <p>INHOUD 5</p>
    </div>
</div>
<div class="enhanceable_content tabs" title="ingesloten inhoud">
    <ul>
        <li><a href="#fragment-1">Regulier traject</a></li>
        <li><a href="#fragment-2">Afstandstraject</a></li>
    </ul>
    <div id="fragment-1">
        <p>INHOUD REGULIER TRAJECT</p>
    </div>
    <div id="fragment-2">
        <p>INHOUD AFSTANDSTRAJECT</p>
    </div>
</div>
star

Fri Mar 29 2024 14:00:53 GMT+0000 (Coordinated Universal Time) https://blog.wolfbolin.com/archives/862

@HappyCoder

star

Fri Mar 29 2024 13:53:05 GMT+0000 (Coordinated Universal Time)

@vladislavruk

star

Fri Mar 29 2024 13:48:49 GMT+0000 (Coordinated Universal Time)

@rstringa #color-mix

star

Fri Mar 29 2024 13:04:29 GMT+0000 (Coordinated Universal Time)

@divyasoni23 #tailwindcss #css

star

Fri Mar 29 2024 13:03:07 GMT+0000 (Coordinated Universal Time)

@divyasoni23 #sass #css

star

Fri Mar 29 2024 13:02:29 GMT+0000 (Coordinated Universal Time)

@divyasoni23 #javascript #jquery

star

Fri Mar 29 2024 12:32:45 GMT+0000 (Coordinated Universal Time)

@vladislavruk

star

Fri Mar 29 2024 12:22:02 GMT+0000 (Coordinated Universal Time) https://pythonprinciples.com/reference/

@wiseteacher

star

Fri Mar 29 2024 12:04:13 GMT+0000 (Coordinated Universal Time) https://www.codecademy.com/learn/learn-recursion-python/modules/recursion-python/cheatsheet

@wiseteacher

star

Fri Mar 29 2024 12:01:56 GMT+0000 (Coordinated Universal Time) https://www.codecademy.com/learn/learn-recursion-python/modules/recursion-conceptual/cheatsheet

@wiseteacher

star

Fri Mar 29 2024 11:39:55 GMT+0000 (Coordinated Universal Time)

@divyasoni23 #javascript #jquery

star

Fri Mar 29 2024 11:37:46 GMT+0000 (Coordinated Universal Time)

@divyasoni23 #css

star

Fri Mar 29 2024 11:16:02 GMT+0000 (Coordinated Universal Time) https://www.freecodecamp.org/news/build-a-snake-game-with-react-redux-and-redux-sagas/

@trt4325 #javascript

star

Fri Mar 29 2024 11:15:44 GMT+0000 (Coordinated Universal Time) https://www.freecodecamp.org/news/build-a-snake-game-with-react-redux-and-redux-sagas/

@trt4325 #javascript

star

Fri Mar 29 2024 08:44:19 GMT+0000 (Coordinated Universal Time)

@StefanoGi

star

Fri Mar 29 2024 06:06:52 GMT+0000 (Coordinated Universal Time) https://stackoverflow.com/questions/64032166/tailwindcss-not-working-with-next-js-what-is-wrong-with-the-configuration

@jaimin #javascript

star

Fri Mar 29 2024 05:07:07 GMT+0000 (Coordinated Universal Time) https://codepen.io/Jondar/pen/LYGKbBG/a87e75f9c27590e683578f712253bd29

@Jondar #undefined

star

Fri Mar 29 2024 04:50:38 GMT+0000 (Coordinated Universal Time) https://chat.openai.com/c/3b5c2278-473d-438e-9e61-751049b61730

@nisarg #python #alchemy

star

Fri Mar 29 2024 04:31:15 GMT+0000 (Coordinated Universal Time) https://docs.sqlalchemy.org/en/20/tutorial/engine.html

@nisarg #python #alchemy

star

Fri Mar 29 2024 04:17:35 GMT+0000 (Coordinated Universal Time) https://docs.sqlalchemy.org/en/20/intro.html#installation

@nisarg #python #alchemy

star

Fri Mar 29 2024 01:30:36 GMT+0000 (Coordinated Universal Time) https://leetcode.com/problems/insert-interval/description/

@playadust

star

Thu Mar 28 2024 18:00:42 GMT+0000 (Coordinated Universal Time)

@Jondar

star

Thu Mar 28 2024 15:37:58 GMT+0000 (Coordinated Universal Time)

@chanuth

star

Thu Mar 28 2024 15:36:48 GMT+0000 (Coordinated Universal Time)

@chanuth

star

Thu Mar 28 2024 12:52:42 GMT+0000 (Coordinated Universal Time)

@hardikraja #commandline #pycharm

star

Thu Mar 28 2024 12:36:52 GMT+0000 (Coordinated Universal Time)

@Anomoly

star

Thu Mar 28 2024 12:25:02 GMT+0000 (Coordinated Universal Time)

@cvataicode #python

star

Thu Mar 28 2024 12:23:26 GMT+0000 (Coordinated Universal Time)

@cvataicode #python

star

Thu Mar 28 2024 12:22:11 GMT+0000 (Coordinated Universal Time)

@cvataicode #python

star

Thu Mar 28 2024 12:11:20 GMT+0000 (Coordinated Universal Time)

@cvataicode #python

star

Thu Mar 28 2024 12:00:43 GMT+0000 (Coordinated Universal Time)

@cvataicode #python

star

Thu Mar 28 2024 11:59:48 GMT+0000 (Coordinated Universal Time)

@cvataicode #python

star

Thu Mar 28 2024 11:06:44 GMT+0000 (Coordinated Universal Time)

@Shmotyu

star

Thu Mar 28 2024 10:44:21 GMT+0000 (Coordinated Universal Time)

@cvataicode #python

star

Thu Mar 28 2024 10:43:21 GMT+0000 (Coordinated Universal Time)

@cvataicode #python

star

Thu Mar 28 2024 10:42:05 GMT+0000 (Coordinated Universal Time)

@cvataicode #python

star

Thu Mar 28 2024 10:39:35 GMT+0000 (Coordinated Universal Time)

@cvataicode #python

star

Thu Mar 28 2024 10:37:46 GMT+0000 (Coordinated Universal Time)

@cvataicode

star

Thu Mar 28 2024 10:35:39 GMT+0000 (Coordinated Universal Time)

@cvataicode #json

star

Thu Mar 28 2024 09:18:02 GMT+0000 (Coordinated Universal Time)

@felipems #javascript

star

Thu Mar 28 2024 09:08:48 GMT+0000 (Coordinated Universal Time)

@Jevin2090

star

Thu Mar 28 2024 08:50:59 GMT+0000 (Coordinated Universal Time)

@Jevin2090

star

Thu Mar 28 2024 08:48:38 GMT+0000 (Coordinated Universal Time)

@Jevin2090

star

Thu Mar 28 2024 07:28:03 GMT+0000 (Coordinated Universal Time)

@HTPrince

star

Wed Mar 27 2024 23:43:17 GMT+0000 (Coordinated Universal Time)

@rogueta #bash

star

Wed Mar 27 2024 16:58:44 GMT+0000 (Coordinated Universal Time)

@Lester695 #html

star

Wed Mar 27 2024 16:55:25 GMT+0000 (Coordinated Universal Time)

@Lester695 #html

Save snippets that work with our extensions

Available in the Chrome Web Store Get Firefox Add-on Get VS Code extension