Skip to content

Instantly share code, notes, and snippets.

View abhitheawesomecoder's full-sized avatar

Abhishek Kumar abhitheawesomecoder

View GitHub Profile
//fibonaci series using recursion
void main() {
seq(5);
}
seq(int n){
if(n < 0){
return n;
}else{
if(n < 2)
print(n);
var key = aesjs.utils.utf8.toBytes("j3u8ue8xmrhsth59");
// Convert text to bytes
var text = 'GLGqOsjCQejV8wvNflrKvXkNfvYYR+eqogEn8payz3MHk8VLK5Wet0Y6F6c6L5yoXvsMZ5SEwHD5boeNuc5hcdKXOMDhu31T3kLNGPxOcfL0oiv78pP4MmLeekQWvfZbbKNdsAEaXwU5VHFN4SMKNwAhAKoCOrqCKrv4V9W4odwQDOFQpmogxPD2iLMCUAVkzQZB+aqAg4r6yranT/uGvvImPe+jlOH8I28qWGCPEtCM5N+n/QiQrJ+lZHK8SJgnnBsLJdj778/0Maiqx7huyAmnHJx0vxbH+gv+zsrtrIr8x++io+genj8pabVmN1e1';
var textEnc = '{"dataId":"00058F9C9BE9A2D4BBCE67122FB80002","devId":"175540103c71bf20df5a","productKey":"66mNaBqLdsYhX5lA","status":[{"1":"true","code":"switch","t":1565277677005,"value":true},{"2":"0","code":"countdown_1","t":1565277677005,"value":0}]}';
function _base64ToBytesr(base64) {
var binary_string = window.atob(base64);
var len = binary_string.length;
var bytes = new Uint8Array( len );
loginUser(){
const _this = this
let formData = new FormData();
const { country_code, email, phone_number } = this.state
const url = "https://api.authy.com/protected/json/users/new?user[email]="+email+"&user[cellphone]="+phone_number+"&user[country_code]="+country_code+"&send_install_link_via_sms=false"
fetch(url,{
method: 'POST',
headers: {
'X-Authy-API-Key': '4936D0XWwTtjJaMGmboOaytduK43FMTu'
}
import React from 'react';
import { View, Text } from 'react-native';
import { createStackNavigator } from 'react-navigation';
import Home from './src/Home';
export default createStackNavigator({
Home: {
screen: HomeScreen
},
import React from 'react';
import { View, Text } from 'react-native';
export default class HomeScreen extends React.Component {
render() {
return (
<View style={{ flex: 1, alignItems: 'center', justifyContent: 'center' }}>
<Text>Home Screen</Text>
</View>
);
import React from 'react';
import { View, Text } from 'react-native';
import { createStackNavigator } from 'react-navigation';
class HomeScreen extends React.Component {
render() {
return (
<View style={{ flex: 1, alignItems: 'center', justifyContent: 'center' }}>
<Text>Home Screen</Text>
</View>
import React, { Component } from 'react';
import { StyleSheet, Text, View, Button, DatePickerAndroid, TimePickerAndroid, Picker, AppRegistry, TouchableOpacity } from 'react-native';
//import AvailableDates from '../Calendar/Calendar';
//import { Calendar, CalendarList } from 'react-native-calendars';
let arrBooked = []
const availableHours = {
"timeSlots": {
"slot1": "2:00pm to 2:30pm",
import React from 'react'
import { AsyncStorage } from 'react-native';
import { ApolloProvider, createNetworkInterface, ApolloClient } from 'react-apollo'
import Mainuser from './components/mainuser'
import Login from './components/Login'
import Register from './components/Register'
const networkInterface = createNetworkInterface({ uri: 'http://192.168.1.3:4000/graphql'
})
const Constants = {
SECRET: 'iloveyou'
}
export default Constants
import express from 'express';
import { graphqlExpress, graphiqlExpress } from 'apollo-server-express';
import bodyParser from 'body-parser';
import schema from './data/schema';
import cors from 'cors';
import jwt from 'express-jwt';
import Constants from './constants';
import { User } from './data/connectors';
const GRAPHQL_PORT = 4000;