Skip to content

Instantly share code, notes, and snippets.

View rudr4x5h's full-sized avatar
Rolling Magic

Adarsh rudr4x5h

Rolling Magic
  • Bharat (i.e. India)
  • 21:08 (UTC +05:30)
View GitHub Profile
@rudr4x5h
rudr4x5h / keybase.md
Created May 2, 2022 04:43
Keybase verification

Keybase proof

I hereby claim:

  • I am datasapient on github.
  • I am adarshpathak (https://keybase.io/adarshpathak) on keybase.
  • I have a public key ASD6iA4RdVsti85kenVj_0HhPNPEoEA1S6lAfrThT4RDvwo

To claim this, I am signing this object:

@rudr4x5h
rudr4x5h / keybase.md
Created November 30, 2017 14:44
Keybase

Keybase proof

I hereby claim:

  • I am d3vil0p3r on github.
  • I am d3vil0p3r (https://keybase.io/d3vil0p3r) on keybase.
  • I have a public key ASBUrv4WdKEMkwwnzVXbFInkGfnPaiqsjrNpXIA_LcYnEwo

To claim this, I am signing this object:

@rudr4x5h
rudr4x5h / gist:b2d6f3806b84ddb8fc7cf7869e79f00d
Created October 20, 2017 09:18 — forked from CristinaSolana/gist:1885435
Keeping a fork up to date

1. Clone your fork:

git clone [email protected]:YOUR-USERNAME/YOUR-FORKED-REPO.git

2. Add remote from original repository in your forked repository:

cd into/cloned/fork-repo
git remote add upstream git://github.com/ORIGINAL-DEV-USERNAME/REPO-YOU-FORKED-FROM.git
git fetch upstream

How-to setup a simple git push deployment

These are my notes basically. At first i created this gist just as a reminder for myself. But feel free to use this for your project as a starting point. If you have questions you can find me on twitter @thomasf

On the server (example.com)

  1. Create a user on example.com, as which we (the git client) connect (push) to exmaple.com.
sudo useradd -m -s /usr/bin/git-shell git
@rudr4x5h
rudr4x5h / SineSeriesFunction.cpp
Last active April 1, 2017 19:57
Sine function using series expansion
// Computes value of Sine function upto the desired limit using Sine series expansion.
// powered by -> HELL Labs (http://helllabs.in)
#include<math.h>
#include<stdio.h>
int main()
{
int times = 8, value = 10; // default values, should return -215.751221
scanf("%d", &times);
"""
Our Aim is to check whether the given "number" is a perfect square as well as a perfect cube or not.
"""
def cuber(num): # Calculates whether the given number is a perfect cube or not.
inte = int(round(num**(1/3.0000000)))
if num == inte**3:
return True
else:
return False