Skip to content

Instantly share code, notes, and snippets.

View kamaravichow's full-sized avatar
🦉
Can't sleep

Aravind Chowdary kamaravichow

🦉
Can't sleep
View GitHub Profile
@kamaravichow
kamaravichow / wordpress.php
Created March 27, 2024 09:13
Template for WPCode snippet for an api call
<?php
function call_api() {
// Check if the request is coming from the correct origin
$prompt = $_POST['prompt'];
$api_url = "";
$headers = [
'Content-Type' => 'application/json',
];
@kamaravichow
kamaravichow / answer.py
Created March 22, 2024 04:58
Run it with python answer.py or python3 answer.py
# Define a function called plus_five() that adds 5 to its argument.
# Then, define another function named m_by_3() that multiplies the argument (the result obtained from plus_five()) by 3.
# Verify your code was correct by calling the second function with an argument of 5.
# Was your output equal to 30?
def plus_five(number):
return number + 5
def m_by_3(number):
return number * 3
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
#include <SparkFun_HIH4030.h> // Include header files for I2C connectivity support
#include <Wire.h>
int tempAddress = 0x48; // I2C: TMP102 Slave Address with ADD0 grounded
float temp = 0; // Temperature value either Static or Sensor Reading
int tempSensor = 0; // If you are using Temperature Sensor (0 = No / 1 = YES)
   -> Installing AppLovinSDK (6.2.0)
    > Http download
      $ /usr/bin/curl -f -L -o /var/folders/wl/xhcccn7d6070dp98421p71nc0000gn/T/d20220929-25871-y4zqv1/file.zip https://bintray.com/applovin/iOS/download_file?file_path=applovin-ios-sdk-6.2.0.zip --create-dirs --netrc-optional --retry 2 -A 'CocoaPods/1.11.3 cocoapods-downloader/1.5.1'

   [!] Error installing AppLovinSDK
   [!] /usr/bin/curl -f -L -o /var/folders/wl/xhcccn7d6070dp98421p71nc0000gn/T/d20220929-25871-y4zqv1/file.zip https://bintray.com/applovin/iOS/download_file?file_path=applovin-ios-sdk-6.2.0.zip --create-dirs --netrc-optional --retry 2 -A 'CocoaPods/1.11.3 cocoapods-downloader/1.5.1'

Error output from CocoaPods:
↳
"use strict";
function deobf() {
try {
var e = document.getElementById("in").value;
if ("" === e) throw "Empty";
document.getElementById("out").value = "";
var f = e.match(/\+CVars=([\S]+)/g);
if (null === f) throw "No matching parameters were found";
f = f.map(function(a) {
@kamaravichow
kamaravichow / CircularProgressView.swift
Created March 7, 2022 17:13
iOS version of gradient circular progress bar SwiftUI
import SwiftUI
struct CircularProgressView: View {
var progress = 10.0
var body: some View {
ZStack {
@kamaravichow
kamaravichow / circular-progress.kt
Created March 7, 2022 16:50
Composable function for circular progress bar with gradience and animation in Jetpack Compose
@Composable
fun CircularProgressBar(
percentage: Float,
radius: Dp = 80.dp,
animationDuration: Int = 1000,
) {
var animFinished by remember {
mutableStateOf(false)
}
import 'package:flutter/material.dart';
import 'package:flutter_blocks_site/pages/side_bar.dart';
class HomePage extends StatefulWidget {
static GlobalKey<ScaffoldState> scaffoldKey = GlobalKey();
const HomePage({Key? key}) : super(key: key);
@override
_HomePageState createState() => _HomePageState();
}
{
"status": 200,
"message": "success",
"formats": [
{
"url":"",
"title" : "",
"resolution":"",
"thumbnail":"",
"duration":""