Skip to content

Instantly share code, notes, and snippets.

@abdullahnaseer
abdullahnaseer / multiply.asm
Last active May 7, 2018 19:41
String digits multiplication in MASM
.386
.model flat, stdcall
.stack 1024
GetStdHandle PROTO, ; get standard handle
nStdHandle:DWORD ; type of console handle
;Returns: (HANDLE) EAX = A handle to the specified device,
; or INVALID_HANDLE_VALUE flag if function fails.
ReadConsoleA PROTO,
@abdullahnaseer
abdullahnaseer / main.asm
Last active May 22, 2018 08:25
COAL Project
.386
.model flat, stdcall
.stack 1024
GetTickCount PROTO ; get elapsed milliseconds
; since computer turned on
ExitProcess PROTO, ; exit program
dwExitCode:DWORD ; return code
@abdullahnaseer
abdullahnaseer / get_ip_function.php
Created August 12, 2021 08:07
IP Function for Google Cloud Function (For Purpose of Upwork Test Only)
<?php
use GuzzleHttp\Psr7\Response;
use Psr\Http\Message\ServerRequestInterface;
function get_ip(ServerRequestInterface $request)
{
$data = ["ip" => get_client_ip()];
$queryString = $request->getQueryParams();
@abdullahnaseer
abdullahnaseer / VTest.vue
Created January 2, 2022 09:53
Vue Test - Computed Property
<template>
<div class="widget">
<div v-if="activeItems && activeItems.length > 0">
<ul>
<li
v-for="item in activeItems"
:key="item.id"
>
{{ item.name }}
</li>
@abdullahnaseer
abdullahnaseer / CustomerService.php
Created January 2, 2022 10:23
CustomerService - Evaluation of Laravel
<?php
namespace App\Services;
use App\Mail\WelcomeNewCustomer;
use Illuminate\Support\Facades\DB;
use Illuminate\Support\Facades\Mail;
class CustomerService
{
@abdullahnaseer
abdullahnaseer / CustomerController.php
Created January 2, 2022 10:24
CustomerController - Evaluation of Laravel
<?php
namespace App\Http\Controllers;
use App\Http\Requests\Customer\CustomerStoreRequest;
use App\Services\CustomerService;
class CustomerController extends Controller
{
public function __construct(protected CustomerService $customerStoreService)
@abdullahnaseer
abdullahnaseer / CustomerStoreTest.php
Created January 2, 2022 10:53
Customer Store Test - Evaluation of Laravel
<?php
namespace Tests\Unit;
use App\Mail\WelcomeNewCustomer;
use Tests\TestCase;
use Illuminate\Support\Facades\Mail;
class CustomerStoreTest extends TestCase
{