text stringlengths 184 4.48M |
|---|
import React, {FC, useMemo, useState} from 'react';
import {Question, QuestionType} from '../../interfaces/Question';
import {shuffleArray} from '../../../../__mocks__/questionsList';
interface Props {
question: Question;
checkAnswer: (answer: string) => void;
disabled: boolean;
}
export const QuestionOpt... |
package com.sky.task;
import com.sky.entity.Orders;
import com.sky.mapper.OrderMapper;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;
import java.time.LocalDat... |
//TIP To <b>Run</b> code, press <shortcut actionId="Run"/> or
// click the <icon src="AllIcons.Actions.Execute"/> icon in the gutter.
fun main() {
var adam = Human("Adam", 44)
adam.age++
var adamCopy = Human("Adam", 45)
val eve = Human("Eve", 44)
println(adam.equals(eve)) //false
println(adam =... |
@testable
import App
import ComposableArchitecture
import Core
import XCTest
@MainActor
final class TodayReducerTests: XCTestCase {
func testDidLoad() async throws {
let feed1 = Feed(slug: "1", title: "Tecnologia", collection: "1", emoji: "1", weight: 1)
let feed2 = Feed(slug: "2", title: "Sport", collection... |
import csv
import sys
import check50
from util import Node, StackFrontier, QueueFrontier
# Maps names to a set of corresponding person_ids
names = {}
# Maps person_ids to a dictionary of: name, birth, movies (a set of movie_ids)
people = {}
# Maps movie_ids to a dictionary of: title, year, stars (a set of person_id... |
/*
* Copyright (c) 2021-2022 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable... |
<template>
<div>
<TodoInputForm
ref="TodoInputForm"
:propTodos="todos"
:loginToken="loginToken"
@todos:push="todos.push($event); updateTree()"
>
</TodoInputForm>
<TodoTree
ref="TodoTree"
:propTodos="todos"
:state="state"
:loginToken="loginToken"
... |
<?php
namespace MailPoet\API\JSON\v1;
if (!defined('ABSPATH')) exit;
use Exception;
use MailPoet\API\JSON\Endpoint as APIEndpoint;
use MailPoet\API\JSON\Error;
use MailPoet\API\JSON\Error as APIError;
use MailPoet\API\JSON\Response;
use MailPoet\API\JSON\ResponseBuilders\FormsResponseBuilder;
use MailPoet\API\JSON\... |
import React, { useState } from 'react';
import { FormProvider, SubmitHandler, useForm } from 'react-hook-form';
import Modal from 'react-modal';
import { yupResolver } from '@hookform/resolvers/yup';
import { BsPlusLg } from 'react-icons/bs';
import customStyles from '../../../styles/modalStyles';
import SubmitButton ... |
import { Options } from './options';
import {Component, NgModule} from '@angular/core'
;
import {BrowserModule} from '@angular/platform-browser';
@Component({
selector: 'app-root',
templateUrl: './app.component.html'
})
export class AppComponent {
selectedOption:Options = new Options(2, 'T-Shirts',1000,tru... |
package org.semanticweb.owlapi.util;
import org.semanticweb.owlapi.model.*;
import java.util.List;
import java.util.Map;
/*
* Copyright (C) 2007, University of Manchester
*
* Modifications to the initial code base are copyright of their
* respective authors, or their employers as appropriate. Authorship
* of th... |
import 'package:flutter/material.dart';
import 'package:movies_app/common/common.dart';
import 'package:movies_app/ui/ui.dart';
class LoginScreen extends StatefulWidget {
const LoginScreen({Key? key}) : super(key: key);
@override
State<LoginScreen> createState() => _LoginScreenState();
}
class _LoginScreenStat... |
//
// ViewController.swift
// ToDoList
//
// Created by Joseph Estanislao Calla Moreyra on 28/11/22.
//
import UIKit
import CoreData
class ViewController: UIViewController {
@IBOutlet weak var table: UITableView!
var listTask = [Tarea]()
let contexto = (UIApplication.shared.delegate as! AppDelegate).p... |
import * as React from 'react';
import { useEffect, useState } from 'react';
import PropTypes from 'prop-types';
import { alpha } from '@mui/material/styles';
import Box from '@mui/material/Box';
import Table from '@mui/material/Table';
import TableBody from '@mui/material/TableBody';
import TableCell from '@mui/materi... |
package frc.robot.subsystems.shooter;
import org.littletonrobotics.junction.Logger;
import edu.wpi.first.wpilibj2.command.SubsystemBase;
import edu.wpi.first.math.controller.SimpleMotorFeedforward;
import frc.robot.constants.ShooterConstants;
public class Shooter extends SubsystemBase {
private final ShooterIO i... |
import sys
import time
from flask import json
import pika
import requests
API_BASE_URL = "http://api-gis:8080"
POLLING_FREQ = int(sys.argv[1]) if len(sys.argv) >= 2 else 30
ENTITIES_PER_ITERATION = int(sys.argv[2]) if len(sys.argv) >= 3 else 10
def fetch_data_from_api(endpoint):
try:
response = requests.g... |
<!DOCTYPE html>
<html>
<head>
<style>
canvas {
border: 1px solid #000;
}
#inspectorbg {
position: absolute;
left: 811px;
top: 8px;
width: 300px;
height: 600px;
background-color: lightgray;
border: 1px solid black;
}
#undo
{
position: absolute;
left: 20px;
top: 300... |
import React, { useContext, useState } from 'react'
import { Text, View, TextInput, StyleSheet, Button } from 'react-native'
import UsersContext from '../context/UsersContext'
export default ({ route, navigation }) => {
const [user, setUser] = useState(route.params ? route.params : {}) // verifica se route.params ex... |
/*******************************************************************************
* Rhythos Game is the base game client which runs games exported from the editor.
*
* Copyright (C) 2013 David Maletz
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser ... |
/**
* (C) 2010-2012 Alibaba Group Holding Limited.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* version 2 as published by the Free Software Foundation.
*
* Version: $Id$
*
* ob_expr_obj.h
*
* Authors:
* Zhifeng YANG <zhuw... |
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>TODO App</title>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bulma@0.9.3/css/bulma.min.css">
<link... |
/**************************************************************************
**
** This file is part of Qt Creator
**
** Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
**
** Contact: Nokia Corporation (qt-info@nokia.com)
**
** Commercial Usage
**
** Licensees holding valid Qt Commercial licenses may u... |
import 'package:dartz/dartz.dart';
import 'package:equatable/equatable.dart';
import 'package:flutter/material.dart';
import 'package:wmd/core/domain/usecases/usercase.dart';
import 'package:wmd/core/error_and_success/failures.dart';
import 'package:wmd/core/error_and_success/succeses.dart';
import 'package:wmd/feature... |
from classes.scraping.get_html import get_html_champions, get_html_champion
def get_champion_list(new_patch: bool):
doc = get_html_champions(new_patch)
table = doc.find("td", attrs={"data-sort-value": "Aatrox"}).parent.parent
i = 0
champion_list = []
for entry in table:
if i <= 2:
... |
import React, { useEffect, useState } from "react";
import { useNavigate } from "react-router-dom";
import Container from "../Container";
import Title from "../form/Title";
import FormInput from "../form/FormInput";
import Submit from "../form/Submit";
import CustomLink from "../CustomLink";
import { commonModalClasse... |
import { useRouter } from "next/router";
import { useEffect } from "react";
import { Formik, Form, Field } from "formik";
import { object, string } from "yup";
import PageWidth from "components/PageWidth/PageWidth";
import { Title } from "components/Title/Title";
import InputField from "components/form-fields/InputFiel... |
import {useState, useEffect} from 'react'
function useLocalStorage(key, initialValue) {
const [value, setValue] = useState(() => {
const jsonValue = localStorage.getItem(key)
if(jsonValue == null){
if(typeof initialValue === "function"){
return initialValue()
}else{
r... |
import { AfterViewInit, Component, ElementRef, ViewChild } from '@angular/core';
import { FormControl, FormGroup, FormsModule, ReactiveFormsModule, Validators } from '@angular/forms';
import { TransizioneService } from '../../servizio-transizione.service';
import { Router } from '@angular/router';
import { InputCodiceC... |
<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head th:replace="fragmentos/cabecera.html :: cabecera('Editar Sede')">
</head>
<body>
<nav th:replace="fragmentos/navbar.html :: navbar('sedes')">
</nav>
<main>
<div class="container px-4 py-5">
... |
<?php
namespace Mpdf;
use Mpdf\Strict;
use Mpdf\Color\ColorConverter;
use Mpdf\Image\ImageProcessor;
use Mpdf\Language\LanguageToFontInterface;
class Tag
{
use Strict;
/**
* @var \Mpdf\Mpdf
*/
private $mpdf;
/**
* @var \Mpdf\Cache
*/
private $cache;
/**
* @var \Mpdf\CssManager
*/
private $cssM... |
# Sliding Window
class Solution:
def getMaxLen(self, nums: List[int]) -> int:
max_len = 0
negative_count = 0
first_negative_index = None
zero_index = -1
for i in range(len(nums)):
if nums[i] == 0:
negative_count = 0
first_negative_... |
package io.github.dtolmachev1.operations.complex;
import io.github.dtolmachev1.numbers.Complex;
import io.github.dtolmachev1.operations.Operation;
/**
* <p>Class for multiplication operation.</p>
*/
class Multiplication implements Operation {
/**
* <p>Constructor to initialize operation with given operands... |
import { Link } from 'react-router-dom';
import { AlbumType } from '../types';
type PropsType = {
result: AlbumType;
};
function ArtistCollectionCard({ result }: PropsType) {
const {
artistName,
collectionId,
collectionName,
collectionPrice,
artworkUrl100,
releaseDate,
trackCount,
... |
package main
import (
"crypto/tls"
"crypto/x509"
"fmt"
"github.com/dgraph-io/badger/v4"
"github.com/gin-gonic/gin"
mdns "github.com/miekg/dns"
_ "github.com/qdnqn/smr/docs"
"github.com/qdnqn/smr/pkg/api"
"github.com/qdnqn/smr/pkg/commands"
_ "github.com/qdnqn/smr/pkg/commands"
"github.com/qdnqn/smr/pkg/conf... |
require 'debug'
# Parserクラスでincludeするためのモジュール
# 汎用的なメソッドを定義する
module Concerns::Util
private
def match(*types)
types.each do |type|
if check(type)
advance
return true
end
end
false
end
# Tokenを消費して、インデックスを1つ進める
def consume(type, message)
return advance if check(typ... |
import pandas as pd
def take_user_input():
"""As described, needs unpacking/unrolling params when called"""
while True:
try:
p = int(input("Write parameter p: "))
q = int(input("Write parameter q: "))
c = int(input("Write ciphered message c: "))
return p... |
/* eslint-disable react/prop-types */
import { useState } from "react";
import { Link } from "react-router-dom";
import logo from "../assets/logo.png";
import { useLogout } from "../Hooks/useLogout.jsx";
import logoutImg from "../assets/logout.png";
function NewContact({ onAddContact }) {
const { logout } = useLogo... |
// Name : lab11.cpp
// Author : Khalid Mengal
// Version : 1.0
// Date Created : 25-04-2020
// Date Modified: 18-11-2021
// Copyright : All rights are reserved
// Description : HashTable Implmentation using C++
#include<iostream>
#include<fstream>
#include<sstream>
#include<math.h>
#include<s... |
import sys
import torch as th
from lib.ChamferDistancePytorch.chamfer3D.dist_chamfer_3D import chamfer_3DDist
from lib.PyTorchEMD.emd import earth_mover_distance as EMD
from pytorch3d.ops import knn_points, sample_points_from_meshes
from pytorch3d.structures import Meshes
from src.utils import BlackHole
from torch_sca... |
<?php
namespace App\Controllers;
use App\Controllers\BaseController;
use CodeIgniter\HTTP\ResponseInterface;
class Login extends BaseController
{
public function index()
{
return view('halaman-login');
}
public function prosesLogin()
{
$validation = \Config\Services::validation()... |
package com.codingdojo.loginAndRegistration.models;
import java.util.Date;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.PrePersist;
import javax.persistence.PreUpdate;
import javax.persistence.T... |
import express from 'express';
import dotenv from 'dotenv';
dotenv.config();
import routes from './routes/index.js'
import morgan from 'morgan';
const helmet = require('helmet');
import { boomErrorHandler, errorHandler, logErrors } from './middlewares/error.handler.js';
import cors from 'cors'
import connection from '.... |
/*
* ledmag - Display portion of screen on a LED-Setup using libniftyled
* Copyright (C) 2006-2014 Daniel Hiepler <daniel@niftylight.de>
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Softwa... |
//------------------------------------------------------------------------
// Project : SDK Base
// Version : 1.0
//
// Category : Helpers
// Filename : base/source/fobject.cpp
// Created by : Steinberg, 2008
// Description : Basic Object implementing FUnknown
//
//---------------------------------------... |
import React from "react";
import { FaTicketAlt } from "react-icons/fa";
const Cart = ({ tickets }) => {
const getSportIcon = (evenement) => {
switch (evenement) {
case "Athlétisme":
return (
<img
className="object-cover size-[200px]"
src="src\evenements\atle.jpg"
... |
class Post < ApplicationRecord
has_rich_text :hello
validates :title, presence: true
validates :serial, uniqueness: true
belongs_to :board
belongs_to :user
has_many :comments
has_one_attached :photo
before_create :create_serial
def display_username
if user.nil?
"-"
else
user.ac... |
import {
Alert,
Autocomplete,
Avatar,
Box,
Button,
Dialog,
DialogActions,
DialogContent,
DialogTitle,
Fab,
Grid,
Snackbar,
} from '@mui/material';
import AddAPhotoIcon from '@mui/icons-material/AddAPhoto';
import { useEffect, useState } from 'react';
import {
getCateg... |
package com.github.mohammadsianaki.currencyexchange.core_common.base
import androidx.lifecycle.ViewModel
import com.github.mohammadsianaki.currencyexchange.core_common.coroutine.CoroutineDispatcherProvider
import com.github.mohammadsianaki.currencyexchange.core_common.coroutine.DispatcherProvider
import kotlinx.corout... |
import { useState } from "react";
import s from "./style.module.css";
import logo from "assets/trash.svg";
import { ButtonAddAnnonces } from "components/ButtonAddAnnonces/ButtonAddAnnonces";
export function AnnonceCard({
title,
date,
image,
content,
onClickNavigate,
onClickDelete,
}) {
// STATE POUR LE C... |
Given a class Employee. Your task is to create your own **comparator** and implement method `Set<Employee> getEmployeesByOrder(List<Employee> employees)` that takes List of Employees.
This method should return sorted set of Employees by age and names:
- Firstly, sort employees from younger to older.
- If the age ... |
package com.junghun.common.domain.gathering.service;
import com.junghun.common.domain.gathering.dto.ClubGatheringUploadDto;
import com.junghun.common.domain.gathering.model.ClubGathering;
import com.junghun.common.domain.like.dto.LikeObjectDto;
import com.junghun.common.domain.like.exception.AlreadyLikeException;
impo... |
import CIcon from "@coreui/icons-react";
import {
CButton,
CCard,
CCardBody,
CCardFooter,
CCardHeader,
CCol,
CForm,
CFormGroup,
CInput,
CInputFile,
CLabel,
CRow,
CSelect,
} from "@coreui/react";
import dateFormat from "dateformat";
import React, { useState } from "react";
import { useDispatch ... |
/*
* speech.cxx
*
* Text To Speech and Speech Recognition classes
*
* Portable Windows Library
*
* Copyright (c) 2002 Equivalence Pty. Ltd.
*
* The contents of this file are subject to the Mozilla Public License
* Version 1.0 (the "License"); you may not use this file except in
* compliance with the License.... |
import { plainToClass } from 'class-transformer';
import { Request, Router } from 'express';
import { CreateSampleEntityBody } from '../domains/sample-domain/api/create-sample-entity-body';
import { SampleEntityType } from '../domains/sample-domain/api/sample-entity-type';
import { SampleEntity } from '../domains/sampl... |
#!/usr/bin/env python
# coding: utf-8
# In[1]:
# !pip install jsonlines
# In[2]:
import os
import transformers
import torch
import time
import pandas as pd
import numpy as np
import jsonlines # useful
from tqdm import tqdm
from torch.utils.data import Dataset, DataLoader
from transformers import AutoModelForCaus... |
---
title: Dall-E 2 Gallery
description: 3D gallery of Dall-E 2 images
---
<script src="https://aframe.io/releases/1.3.0/aframe.min.js"></script>
<script src="https://cdn.jsdelivr.net/gh/c-frame/aframe-extras@7.0.0/dist/aframe-extras.min.js"></script>
<script src="aframe-lightmap.js"></script>
<script src="https://rawg... |
import json
import datetime
import math
from pathlib import Path
from typing import Any, Union, Mapping, Optional, Iterator
from pymongo.collection import ObjectId
import numpy as np
class JsonEncoder(json.JSONEncoder):
def nan_to_none(self, o):
if isinstance(o, dict):
return {k: self.nan_to... |
import { Component } from 'react';
import css from './Searchbar.module.css';
import Notiflix from 'notiflix';
import { GoSearch } from 'react-icons/go';
export class Searchbar extends Component {
state = {
guery: '',
};
handleChange = e => {
this.setState({ guery: e.currentTarget.value });
};
handleS... |
using System.Diagnostics;
using System.Reflection;
using FluentAssertions;
// ReSharper disable MemberCanBePrivate.Local
namespace Kabua.TypeSafe.xUnit.UnitTests;
public class C51_Custom_InlineObject
{
/// <summary>
/// Derive from <see cref="InlineObjectAttribute"/> to create your custom inline object data... |
import { Action } from "."
export enum TransactionState {
READY,
INITIATED,
WAITING,
SENDING,
DONE,
}
/**
* Waits for the specified action's transaction to be set.
*
* @function waitForTransaction
* @param {Action} action - The action object to check for a transaction.
* @param {function} [lo... |
import { Form, FormInstance, FormProps } from 'antd'
import { createContext, useState } from 'react'
const { useForm } = Form
type AntdFromContextType<T = any> =
| {
form: FormInstance
values: T
}
| undefined
export const AntdFromContext = createContext<AntdFromContextType>(undefined)
AntdFromCo... |
import os
import random
import cv2
from PIL import Image
from io import BytesIO
import numpy as np
import torch
import torchvision.transforms as transforms
import torchvision.transforms.functional as F
from torch.utils.data import Dataset
from utils.utils import open_lmdb
class RotationTransform():
def __init__... |
import os
import requests_cache
# Create the cache directory if it doesn't exist
if not os.path.exists("cache"):
os.makedirs("cache")
# Create the cache
URLS_EXPIRE_AFTER = {
'manifold.markets/api/v0/group/by-id/': 3600 * 3,
'manifold.markets/api/v0/market/': 3600 * 3,
'metaculus.com/api2/questi... |
import { Box, Button, Typography } from "@mui/material";
import React from "react";
import { GameOfLife } from "../../entity/Game";
import { Tile } from "../../entity/tile/ui/Tile";
const game = new GameOfLife();
export const GameBoard = () => {
const [, updateState] = React.useState();
const forceUpdate = React.... |
import 'package:flutter/material.dart';
import 'package:flutter_portfolio/core/global_style/global_color.dart';
import 'package:flutter_portfolio/core/presentation/pages/home.dart';
import 'package:responsive_framework/responsive_framework.dart';
void main() {
runApp(const MyApp());
}
class MyApp extends StatelessW... |
/* eslint-disable react/prop-types */
import React, { useState, useEffect } from 'react';
import { View } from 'react-native';
import * as Animatable from 'react-native-animatable';
import styles from '../utils/styles';
/**
* BubbleOverlay Component.
* Generates an animated overlay of bubbles.
*
* @param {Object}... |
package com.example.e_hotelsapplication
import android.content.ContentValues
import android.content.Intent
import androidx.appcompat.app.AppCompatActivity
import android.os.Bundle
import android.util.Log
import android.widget.Toast
import androidx.appcompat.app.ActionBar
import androidx.core.view.GravityCompat
import ... |
//
// String + Extensions.swift
// Troshko
//
// Created by Faris Hurić on 17. 9. 2023..
//
import Foundation
extension String {
var trimmed: String {
return trimmingCharacters(in: CharacterSet.whitespacesAndNewlines)
}
var localized: String {
return NSLocalizedString(self, comment... |
import { INestApplication, Logger } from '@nestjs/common';
import { ConfigService } from '@nestjs/config';
import { NestFactory } from '@nestjs/core';
import cookieParser from 'cookie-parser';
import helmet from 'helmet';
import SwaggerOptions from './base/core/infrastructure/api/doc/swagger/swagger.options';
import Do... |
---
title: Aspose.Tasks إدارة المشاريع والتخصيص
linktitle: Aspose.Tasks إدارة المشاريع والتخصيص
second_title: Aspose.Tasks .NET API
description: أتقن Aspose.Tasks لـ .NET من خلال برامجنا التعليمية لإدارة المشاريع. تعلم تقنيات المعالجة والتخصيص والتحسين الفعالة لملفات MS Project.
type: docs
weight: 23
url: /ar/net/tasks... |
#+Title: Bootstrapping steps
#+Author: Systems Team
#+SETUPFILE: ./org-templates/level-0.org
#+TAGS: boilerplate(b)
#+EXCLUDE_TAGS: boilerplate
#+OPTIONS: ^:nil
* Install git
#+BEGIN_EXAMPLE
yum install git -y
#+END_EXAMPLE
* Cloning Repository
#+BEGIN_EXAMPLE
git clone https://github.com/vlead/cluster-automatio... |
import { Typography } from '@mui/material'
import React from 'react'
function Title({variant="h6", sx={}, children, ...props}) {
const _component = typeof variant !== 'object'
? variant
: variant.xl
|| variant.lg
|| variant.md
|| variant.sm
|| variant.xs
|| "h6";
const _varia... |
<?php
namespace Drupal\Tests\Core\EventSubscriber;
use Drupal\Tests\UnitTestCase;
use \Drupal\Core\EventSubscriber\PsrResponseSubscriber;
/**
* @coversDefaultClass \Drupal\Core\EventSubscriber\PsrResponseSubscriber
* @group EventSubscriber
*/
class PsrResponseSubscriberTest extends UnitTestCase {
/**
* The ... |
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<script src="./lib/vue.js"></script>
</head>
<body>
<div id="app">
姓: <input v-model="person.firstName"/> 名: <input v-model="person.lastName" />
<hr/>
计算属性: 全名: {{ fullName }}, {{ fullName }}, {{... |
#ifndef FAIR_2_TASK_ASSIGNMENT_H
#define FAIR_2_TASK_ASSIGNMENT_H
#include <vector>
#include <string>
#include <iostream>
#include <algorithm>
#include "Debug.h"
/*
Elements of programming interview, Sorting: Compute an optimum assignment of tasks
We consider the problem of scheduling n = 2m tasks to be performed by m ... |
package com.encore.test.test;
public class ReferenceMain {
/*
* 기본타입과 참조타입 차이점:
* 기본타입은 선언과 동시에 값을 할당할 수 있다.
* 기본타입은 값을 담는 변수
*
* 그러나
* 참조타입은 선언과 동시에 값을 할당할 수 없다.
* 참조타입은 값을 담는 변수가 아니라, 주소값을 담는 변수이다.
* 주소값을 담기 위해서는 객체생성이 선행되어야 한다.
* 객체 생성시 사용하는 연산자는 new
* new 뒤에는 생... |
# Multipanel Figure with Tikz
This is an example of generating a multipanel figure using Tikz/Latex.
See [figures](./figures/) for more formats.
## Examples
### SVG

### PNG

#### PNG Draft

### PDF... |
package com.springboot.project.controller;
import java.util.List;
import org.springframework.http.HttpStatus;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.ann... |
<template>
<div class="pa-search">
<i class="iconfont icon-search"></i>
<!--type 为search时,根据用户输入修改内容会出错-->
<input ref="search" type="text" class="pa-search-input" v-model="currentValue" :placeholder="placeholder"
@keypress="keypress"/>
<button type="button" class="pa-search-button" v-tap="s... |
import { Schema, model } from "mongoose";
import Joi from "joi";
import {handleMongooseError} from "../helpers/handleMongooseError.js";
const createContactSchema = Joi.object({
name: Joi.string().min(3).required(),
email: Joi.string()
.email({
minDomainSegments: 2,
tlds: { allow: ["com", "net", "or... |
'use strict'; // necessary for es6 output in node
import { browser, element, by, ElementFinder, ElementArrayFinder } from 'protractor';
import { promise } from 'selenium-webdriver';
const expectedH1 = 'Tour of Tasks';
const expectedTitle = `${expectedH1}`;
const targetTask = { id: 11, description: 'Task1' };
const ta... |
CREATE DATABASE demoImageDB;
use demoImageDB;
-- SHOW TABLES;
-- SELECT ROUTINE_NAME
-- FROM information_schema.ROUTINES
-- WHERE ROUTINE_TYPE = 'FUNCTION' AND ROUTINE_SCHEMA = 'database_name';
-- SHOW TRIGGERS;
-- SHOW PROCEDURE STATUS WHERE Db = 'imageDB';
-- User Define Function
CREATE FUNCTION image_sim RETURNS ... |
#pragma once
// cereal
#include <cereal/cereal.hpp>
// cereal archive
#include <cereal/archives/json.hpp>
// cereal std
#include <cereal/types/string.hpp>
#include <cereal/types/vector.hpp>
#include <cereal/types/unordered_map.hpp>
#include <cereal/types/array.hpp>
#include <cereal/types/queue.hpp>
#include <cereal/t... |
import * as me from 'melonjs';
import {setLevel} from "./globals";
class TitleScreen extends me.Stage {
/**
* action to perform on state change
*/
onResetEvent() {
const backgroundImage = new me.Sprite(
me.game.viewport.width / 2,
me.game.viewport.height / 2,
... |
//{ Driver Code Starts
// Initial Template for Java
import java.util.*;
import java.lang.*;
import java.math.*;
import java.io.*;
class GFG {
public static void main(String[] args) throws IOException {
Scanner sc = new Scanner(System.in);
int T = sc.nextInt();
while (T-- > 0) {
... |
import { fetchWithSession, Method } from '@/lib/fetch-with-refresh';
import { ApiPaginatedResponse } from '@/models/api-paginated-response';
import { HelloEvent } from '@/models/hello-event';
export async function getOrganizerEventsPaginated(
pageNumber: number = 1,
pageSize: number = 100,
title?: string,
state?: ... |
import { ShoppingCart } from "@mui/icons-material";
import {
AppBar,
Badge,
IconButton,
List,
ListItem,
Switch,
Toolbar,
Typography,
} from "@mui/material";
import { Box } from "@mui/system";
import { NavLink } from "react-router-dom";
import { history } from "../..";
import { useAppSelector } from "../... |
extends Node2D
class_name RicePot
@onready var timer: Timer = $Timer
@onready var progress: TextureProgressBar = $TextureProgressBar
enum State {IDLE, COOKING, DONE, FINISHED}
const COOKING_TIME = 6
var elapsed_time: int
var state: State = State.IDLE
func update_position() -> void:
position += Vector2(0, -16)
fun... |
<template>
<el-popover
v-model:visible="popoverVisible"
placement="right"
trigger="click"
:show-arrow="false"
>
<template #reference>
<li
class="px-4 cursor-pointer h-9 flex items-center gap-2 rounded-lg bg-[#242A40] transition-colors hover:text-white"
>
<svg-icon nam... |
import { SimpleGrid } from "@chakra-ui/react";
import React from "react";
import { usePageLoading, useTranslations } from "../../../hooks";
import AppText from "../../common/AppText";
import QuizButton from "./QuizButton";
import QuizBox from "./QuizBox";
interface Props {
handleExit: () => void;
handleStart: () =... |
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package com.coryneregnet7.dao;
import org.hibernate.Session;
import org.hibernate.SessionFactory;
import org.hibernate.cfg.Configurati... |
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Ball Drop Physics</title>
<style>
body { margin: 0; overflow: hidden; }
canvas { display: block; }
</style>
</head>
<body>
<script src="https://cdnjs.cloudflare.com/ajax/libs/three.js/r128/three.min.js"></script>
... |
from django import forms
from .models import Regulation
class RegulationForm(forms.ModelForm):
class Meta:
model = Regulation
fields = "__all__"
def __init__(self, *args, **kwargs):
super().__init__(*args, **kwargs)
# Add Bootstrap classes to form fields
for field_n... |
import {useState} from "react";
import image from "../images/login.jpg";
import Link from "next/link";
import axios from "./api/axios";
import Image from "next/image";
const Index = () => {
const onSubmitHandle = async (e) => {
e.preventDefault();
let inputLogin = {
email,
... |
<script lang="ts">
import { createForm } from "svelte-forms-lib";
import { createEventDispatcher } from "svelte";
import {
Answer,
Question,
currentInfobyte,
Infobyte,
Infobit,
baseUrl,
isProd,
} from '$lib/stores/stores';
import { Confirm } from "svelte-confirm";
import Fa from... |
import { Test, TestingModule } from '@nestjs/testing';
import { getRepositoryToken } from '@nestjs/typeorm';
import { Repository } from 'typeorm';
import { Stock } from './entities/stock.entity';
import { StocksController } from './stocks.controller';
import { StocksService } from './stocks.service';
describe('StocksC... |
import React from "react";
import { useDispatch, useSelector } from "react-redux";
import { getMarketChart, marketSelect } from "../marketSlice";
import { Line } from "react-chartjs-2";
import {
Chart as ChartJS,
CategoryScale,
LinearScale,
PointElement,
LineElement,
Title,
Tooltip,
Legend,
Filler,
} ... |
# DevJobs
DevJobs (an Amalitech Technical Training Project)
## Overview
DevJobs is a job search platform that allows users to view job listings, filter jobs by title, location, and full-time positions, and apply for jobs. This application is built using Angular, TypeScript, Tailwind CSS, and hosted on Vercel.
## Custo... |
/* Copyright (C) 2001-2012 Artifex Software, Inc.
All Rights Reserved.
This software is provided AS-IS with no warranty, either express or
implied.
This software is distributed under license and may not be copied,
modified or distributed except as expressly authorized under the terms
of the license ... |
import { useParams } from "react-router-dom";
import { useState, useEffect } from "react";
import ItemCard from "./ItemCard";
import '../styles/itemDetail.css';
const ItemDetail = ({addToDeck, removeFromDeck, deck, isMobile}) => {
const params = useParams();
const [item, setItem] = useState([]);
const [relatedPr... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.