1840. Maximum Building Height

You want to build n new buildings in a city. The new buildings will be built in a line and are labeled from 1 to n. However, there are city restrictions on the heights of the new buildings: The height of each building must be a non-negative integer. The height of the first building must be 0. The height difference between any two adjacent buildings cannot exceed 1. Additionally, there are city restrictions on the maximum height of specific buildings. These restrictions are given as a 2D integer array restrictions where restrictions[i] = [idi, maxHeighti] indicates that building idi must have a height less than or equal to maxHeighti. It is guaranteed that each building will appear at most once in restrictions, and building 1 will not be in restrictions. Return the maximum possible height of the tallest building.
/**
 * @param {number} n
 * @param {number[][]} restrictions
 * @return {number}
 */
var maxBuilding = function(n, restrictions) {
    // Step 1: add building 1
    restrictions.push([1, 0]);
    
    // Step 2: sort
    restrictions.sort((a, b) => a[0] - b[0]);

    // Step 3: left-to-right tighten
    for (let i = 1; i < restrictions.length; i++) {
        const [idPrev, hPrev] = restrictions[i - 1];
        const [id, h] = restrictions[i];
        restrictions[i][1] = Math.min(h, hPrev + (id 

1732. Find the Highest Altitude

There is a biker going on a road trip. The road trip consists of n + 1 points at different altitudes. The biker starts his trip on point 0 with altitude equal 0. You are given an integer array gain of length n where gain[i] is the net gain in altitude between points i and i + 1 for all (0 <= i < n). Return the highest altitude of a point.
/**
 * @param {number[]} gain
 * @return {number}
 */
var largestAltitude = function(gain) {
    // Current altitude as we move through the gain array.
    // We always start at altitude 0.
    let altitude = 0;

    // Track the highest altitude reached at any point.
    // Since we start at 0, the minimum possible highest altitude is 0.
    let highest = 0;

    // Iterate through each change in altitude.
    for (let g of gain) {
        // Apply the gain/loss to the current altitude.
       

FLIP Dual Rest Noise

Advects noise through a flip simulation using the dual rest fields that are advected through the sim when enabled in the flip solver. MUST promote rest_ratio and rest2_ratio attributes from detail to points.
float freq = chf("freq");

float n_rest = noise(v@rest  * freq);
float n_rest_2 = noise(v@rest2 * freq);

float nr = f@rest_ratio;
float nr2 = f@rest2_ratio;

float n = (n_rest * nr + n_rest_2 * nr2) / max(nr + nr2, 0.0001);

f@noise = n;

shareAPIでコピーも共有も実現する

<button class="share-button" type="button" data-open-share>共有する</button>

IELTS 5-13

Gloria
Forthy
451
bank transfer
cats
8:30
clothes
nurse
information bag
weekend
60
married couple

independatble
website
guest

one-day
control
special tools
B
A
C
A
C
well head
carb rock
sensors
by sattelite
4 weeks
cociousness
subcontious


sense organs
concerns
homework
C
E
G


disinclined
altitude

ash card

4136270125297745   06/31  954

1344. Angle Between Hands of a Clock

Given two numbers, hour and minutes, return the smaller angle (in degrees) formed between the hour and the minute hand. Answers within 10-5 of the actual value will be accepted as correct.
/**
 * @param {number} hour
 * @param {number} minutes
 * @return {number}
 */
var angleClock = function(hour, minutes) {
    // Normalize hour 12 → 0
    if (hour === 12) hour = 0;

    const minuteAngle = minutes * 6;    // 6° per minute
    const hourAngle = hour * 30 + minutes * 0.5;    // 30° per hour + 0.5° per minute

    let diff = Math.abs(hourAngle - minuteAngle);
    return Math.min(diff, 360 - diff);
};

Zed Git Push and Commit Task + Keymap

Register an action to do both things in zed text editor
[
  {
      "label": "Git Commit & Push",
      "command": "git add . && git commit -m \"💻🐧 Updates\" && git push",
      "reveal": "never",
   },
 ]

3614. Process String with Special Operations II

You are given a string s consisting of lowercase English letters and the special characters: '*', '#', and '%'. You are also given an integer k. Build a new string result by processing s according to the following rules from left to right: If the letter is a lowercase English letter append it to result. A '*' removes the last character from result, if it exists. A '#' duplicates the current result and appends it to itself. A '%' reverses the current result. Return the kth character of the final string result. If k is out of the bounds of result, return '.'.
/**
 * @param {string} s
 * @param {number} k
 * @return {character}
 */
var processStr = function(s, k) {
    const n = s.length;
    const len = new Array(n).fill(0);

    // Forward: compute lengths
    for (let i = 0; i < n; i++) {
        const c = s[i];
        if (c >= 'a' && c <= 'z') {
            len[i] = (i > 0 ? len[i-1] : 0) + 1;
        } else if (c === '*') {
            len[i] = Math.max(0, (i > 0 ? len[i-1] : 0) - 1); 
        } else if (c === '#') {
            len[i] = (i > 0 

Codice Fiscale Italiano Regex

```
^[A-Za-z]{6}[0-9]{2}[A-Za-z][0-9]{2}[A-Za-z][0-9]{3}[A-Za-z]$
```

Export network agents email addresses from outlook to csv to be imported to sendmsg - VBA Outlook Macro

Option Explicit

Function GetRecipientSMTPAddress(recip As Outlook.Recipient) As String

    Dim pa As Outlook.PropertyAccessor
    Dim smtpAddress As String
    Dim exchUser As Outlook.ExchangeUser

    On Error Resume Next

    If recip.AddressEntry.Type = "EX" Then
        Set exchUser = recip.AddressEntry.GetExchangeUser

        If Not exchUser Is Nothing Then
            smtpAddress = exchUser.PrimarySmtpAddress
        End If
    End If

    If smtpAddress = "" Then
   

how to run a logged test on canada billpyament

E2E_AUTH_TOKEN='JWT' E2E_BASE_URL='http://localhost:3002/' npx playwright test

3612. Process String with Special Operations I

You are given a string s consisting of lowercase English letters and the special characters: *, #, and %. Build a new string result by processing s according to the following rules from left to right: If the letter is a lowercase English letter append it to result. A '*' removes the last character from result, if it exists. A '#' duplicates the current result and appends it to itself. A '%' reverses the current result. Return the final string result after processing all characters in s.
/**
 * @param {string} s
 * @return {string}
 */
var processStr = function(s) {
    let res = [];

    for (const ch of s) {
        if (ch >= 'a' && ch <= 'z') {
            // Append letter
            res.push(ch);

        } else if (ch === '*') {
            // Remove last char if exists
            if (res.length > 0) res.pop();

        } else if (ch === '#') {
            // Duplicate the entire result
            res = res.concat(res);

        } else if (ch === '%') {
            // Re

Top Mem Setup

# topmem Script Setup Notes

**Machine:** Lenovo ThinkPad T14 Gen 2
**OS:** Ubuntu 24.04 LTS (Dual Boot)
**Date:** March 24, 2026

---

## Overview

`topmem` is a shell script that shows memory usage aggregated by process name. Unlike `ps aux` which lists every individual process instance separately, `topmem` collapses multiple instances of the same program (e.g. multiple `node` or `chrome` processes) and shows their combined memory footprint — making it easy to answer "which application is usin

Top Cpu Setup

# topcpu Script Setup Notes

**Machine:** Lenovo ThinkPad T14 Gen 2
**OS:** Ubuntu 24.04 LTS (Dual Boot)
**Date:** March 24, 2026

---

## Overview

`topcpu` is a shell script that shows CPU usage aggregated by process name. Unlike `ps aux` which lists every individual process instance separately, `topcpu` collapses multiple instances of the same program (e.g. multiple `node` or `chrome` processes) and shows their combined CPU footprint — making it easy to answer "which application is consuming 

Monitoring - Top Mem with Watcher

#!/bin/bash

WATCH=false
INTERVAL=30
COUNT=10

if [[ "$1" == "-w" ]]; then
    WATCH=true
    [[ -n "$2" && "$2" =~ ^[0-9]+$ ]] && INTERVAL="$2"
elif [[ -n "$1" ]]; then
    COUNT="$1"
fi

run() {
    free -h | awk '/^Mem:/ {printf "Memory: %s used / %s total\n", $3, $2}'
    echo "────────────────────────────────────────"
    ps aux | awk 'NR>1 {mem[$11]+=$4} END {for (p in mem) printf "%6.2f%% %s\n", mem[p], p}' | sort -nr | head -n "$COUNT"
}

if $WATCH; then
    while true; do
        clear