Answer: JavaScript has both strict and type–converting comparisons:
- Strict comparison (e.g., ===) checks for value equality without allowing coercion
- Abstract comparison (e.g. ==) checks for value equality with coercion allowed
Test Driven Development | |
Main Principle: Write the test case before the implementation of the function (only for unit tests) | |
Convention: | |
1. You should only have one assertion per test case | |
- Why? Because we immediately want to know the cause of the failed test case | |
- Note: Sometimes there is no way around having multiple assertions. | |
Steps: |
Extract Variable = command Option V | |
Run Test = Control Shirt R | |
Extract Method = Highlight Code then Command Option M or Control Alt M (Windows) | |
Go To Test or Create New test if none exists = Command Shift T |
// | |
// main.swift | |
// protocols and delegates | |
// | |
// Created by Paul Franco on 8/16/20. | |
// | |
protocol EmergencyMedicalTechnician { | |
func performCPR() | |
} |
Answer: As a user navigates through, out of, and back to your app, the Activity instances in your app transition through different states in their lifecycle.
To navigate transitions between stages of the activity lifecycle, the Activity class provides a core set of six callbacks: onCreate()
, onStart()
, onResume()
, onPause()
, onStop()
, and onDestroy()
. The system invokes each of these callbacks as an activity enters a new state.
Answer: All APIs of Node.js library are aynchronous that is non-blocking. It essentially means a Node.js based server never waits for a API to return data. Server moves to next API after calling it and a notification mechanism of Events of Node.js helps server to get response from the previous API call.
Source: tutorialspoint.com
Gradle configuration | |
Add this in your project level build.gradle file | |
Under buildscript | |
ext.coroutines_version = "1.3.0" | |
ext.room_version = "2.2.2" | |
ext.glide_version = "4.8.0" | |
ext.nav_version = "2.1.0" | |
ext.daggerVersion = '2.14.1' |
Steps to deploy a Node.js app to DigitalOcean using PM2, NGINX as a reverse proxy and an SSL from LetsEncrypt
If you use the referal link below, you get $10 free (1 or 2 months) https://m.do.co/c/5424d440c63a
I will be using the root user, but would suggest creating a new user