This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fun main(args: Array<String>) { | |
val num1 = readLine()!!.toInt() | |
val num2 = readLine()!!.toInt() | |
val num3 = readLine()!!.toInt() | |
val result = num1 - num2 - num3 | |
println("$result") | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fun main(args: Array<String>) { | |
val num1 = readLine()!!.toInt() | |
val num2 = readLine()!!.toInt() | |
// 読み込んだ数値を掛け算して結果を表示 | |
val result = num1 + num2 | |
println("$result") | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fun main(args: Array<String>) { | |
val num1 = readLine()!!.toInt() | |
val num2 = readLine()!!.toInt() | |
// 読み込んだ数値を掛け算して結果を表示 | |
val result = num1 * num2 * 3 | |
println("$result") | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { useEffect, useRef, useState } from 'react'; | |
import { useFloating } from '@floating-ui/react'; | |
const TooltipInput = () => { | |
const [isFocused, setIsFocused] = useState(false); | |
const referenceElement = useRef(null); | |
const popperElement = useRef(null); | |
const { update } = useFloating(); | |
useEffect(() => { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { getSession, withApiAuthRequired } from '@auth0/nextjs-auth0'; | |
import { NextResponse } from 'next/server'; | |
const GET = withApiAuthRequired(async () => { | |
const session = await getSession(); | |
return NextResponse.json(session?.user); | |
}); | |
export { GET }; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"use client"; | |
import React from "react"; | |
import { useState } from "react"; | |
import useSWR from "swr"; | |
// Add some delay here. | |
const fetcher = (url: string) => | |
Promise.all([ | |
fetch(url), | |
new Promise((res) => setTimeout(res, 600)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"use client"; | |
import React from "react"; | |
import { VictoryPie, VictoryChart, VictoryBoxPlot, VictoryTheme } from "victory"; | |
export default function PieChart(){ | |
return ( | |
<VictoryChart | |
domainPadding={20} | |
theme={VictoryTheme.grayscale}> | |
<VictoryBoxPlot |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export default function Ribbon() { | |
return ( | |
<div className="grid grid-cols-1 gap-4 sm:grid-cols-2 p-7"> | |
<div | |
className="relative flex items-center overflow-hidden space-x-3 rounded-lg border border-gray-300 bg-white px-6 py-5 shadow-sm focus-within:ring-2 focus-within:ring-indigo-500 focus-within:ring-offset-2 hover:border-gray-400 after:block after:absolute after:content-[''] after:border-l-[65px] after:border-l-transparent after:border-b-[65px] after:border-gray-500 after:bottom-0 after:right-0" | |
> | |
<div className="absolute block text-gray-200 text-xs bottom-2 right-2 z-10">既読</div> | |
<div className="flex-shrink-0 py-6"> | |
<img className="h-10 w-10 rounded-full" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use client'; | |
import {useState} from "react"; | |
import Select from "react-select"; | |
const options = [ | |
{value: "line", label: "折れ線グラフ"}, | |
{value: "bar", label: "棒グラフ"}, | |
{value: "pie", label: "円グラフ"}, | |
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from "react"; | |
import { useSearchBox } from "react-instantsearch-hooks-web"; | |
export function CustomSearchBox({ props }: { props: any }) { | |
const { query, refine } = useSearchBox(props); | |
return ( | |
<> | |
<input | |
type="text" |
NewerOlder