Skip to content

Instantly share code, notes, and snippets.

View ImtiazEpu's full-sized avatar
🇵🇸
I stand with Palestine 🇵🇸

Imtiaz Ahmed ImtiazEpu

🇵🇸
I stand with Palestine 🇵🇸
View GitHub Profile
function multiplicationTable(num) {
for (let i = 1; i <= 10; i++) {
const product = num * i;
console.log(`${num} x ${i} = ${product}`);
}
}
// Test the function with different input numbers
multiplicationTable(5);
multiplicationTable(7);
<?php
//Question 1:
//You have a Laravel application with a form that submits user information using a POST request. Write the code to retrieve the 'name' input field value from the request and store it in a variable called $name.
//=============================
Route::post( '/submit', function ( Request $request ) {
// Retrieve the 'name' input field value from the request
$name = $request->input( 'name' );