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
<VirtualHost *:80> | |
# The ServerName directive sets the request scheme, hostname and port that | |
# the server uses to identify itself. This is used when creating | |
# redirection URLs. In the context of virtual hosts, the ServerName | |
# specifies what hostname must appear in the request's Host: header to | |
# match this virtual host. For the default virtual host (this file) this | |
# value is not decisive as it is used as a last resort host regardless. | |
# However, you must set it for any further virtual host explicitly. | |
# ServerName www.example.com |
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
version: '3.8' | |
services: | |
ubuntu: | |
build: . | |
container_name: ubuntu_stack | |
restart: unless-stopped | |
stdin_open: true | |
tty: true | |
volumes: |
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
FROM ubuntu:latest | |
ENV DEBIAN_FRONTEND=noninteractive | |
ENV TZ=Asia/Kolkata | |
LABEL maintainer="vkuberan@gmail.com" | |
CMD echo "Installing Latest Ubuntu along with Apache and PHP...." | |
RUN apt-get update && apt-get upgrade |
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
# | |
# XAMPP settings | |
# | |
<IfModule env_module> | |
SetEnv MIBDIRS "C:/xampp/php5.6/extras/mibs" | |
SetEnv MYSQL_HOME "\\xampp\\mysql\\bin" | |
SetEnv OPENSSL_CONF "C:/xampp/apache/bin/openssl.cnf" | |
SetEnv PHP_PEAR_SYSCONF_DIR "\\xampp\\php5.6" | |
SetEnv PHPRC "\\xampp\\php5.6" |
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
# Right Implementation | |
def cubed(n): | |
return [(x * x * x) for x in n] | |
# Wrong Implementation and it will trigger an error | |
def postive_to_negative(n, j): | |
return [(x * x * x) for x in n] | |
numbers = [1, 2, 3, 4, 5] |
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
def squared(numbers): | |
return [(i * i) for i in numbers] | |
def high_order_func_demo(transform, numbers): | |
return transform(numbers) | |
numbers = [1, 2, 3, 4, 5] | |
result = high_order_func_demo(squared, numbers) | |
print(numbers) |
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
<?php | |
Route::get('customer/delete/{id}', function ($id) { | |
try { | |
$customer = App\Customer::find($id); | |
if($customer->delete()) echo "Customer with ID: $id is deleted"; | |
else echo "Customer with ID: $id is not deleted"; |
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
<!-- Copyright 2011 the Dart project authors. All rights reserved. | |
Use of this source code is governed by a BSD-style license | |
that can be found in the LICENSE file. --> | |
<h2>Dr. Fibonacci's Sunflower Spectacular</h2> | |
<div> | |
<canvas id="canvas" width="300" height="300"></canvas> | |
</div> |