text
stringlengths
1
1.05M
/** * @license * * Use of this source code is governed by an MIT-style license that can be * found in the LICENSE file at https://github.com/IDuxFE/idux/blob/main/LICENSE */ /* eslint-disable @typescript-eslint/no-explicit-any */ import type { AccessorContext } from './composables/useAccessor' import type { Acti...
function matchPlugins(plugins, requirements) { const matchedIndices = []; for (let i = 0; i < plugins.length; i++) { const plugin = plugins[i]; let satisfiesRequirements = true; for (const key in requirements) { if (plugin[key] !== requirements[key]) { satisfiesRequirements = false...
package com.bv.eidss; import android.app.Activity; import android.content.Context; import android.database.Cursor; import android.os.Bundle; import android.support.v4.app.LoaderManager; import android.support.v4.content.Loader; import android.view.LayoutInflater; import android.view.Menu; import android.view...
/* * Copyright (C) 2011 The Android Open Source Project * * 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 app...
(defn find-max [arr] (reduce #(max %1 %2) arr)) (println (find-max [3 4 7 2 1 6])) ; 7
<reponame>bodymovin/skia-buildbot import '../modules/tree-scaffold-sk'; import '../modules/tree-status-sk'; import './index.scss';
#!/usr/bin/env bash repoDir=$(git rev-parse --show-toplevel) cd "$repoDir" printf '========== flake8 ==========\n' ./tests/linters/flake.sh printf '\n========== bandit ==========\n' ./tests/linters/bandit.sh printf '\n========== tests ==========\n' # https://stackoverflow.com/questions/1251999/how-can-i-replace-a-newl...
import numpy as np from scipy.integrate import quadrature def energy_level(n): return -13.6 / (n**2) def weight_function(x): return np.exp(-x) def gaussian_quadrature_integration(func, a, b, n): x, w = np.polynomial.legendre.leggauss(n) integral = 0.0 for i in range(n): integral += w[i] *...