Write a polite but firm email to a landlord who has not fixed the heating for three weeks. I want the repair, not a fight.
Mistral Large 4
Here's a draft you can adapt:
Subject: Urgent repair request – no heating at [property address] since [date]
Dear [Landlord's name],
I hope you're well. I'm writing to follow up on the heating issue at [property address], which was first reported on [date] — three weeks ago. As the weather has turned colder, the lack of heating has made the property increasingly difficult to live in, and I'm concerned about the impact on the property itself (pipes, damp) as well as my health.
I completely understand that repairs take time to arrange, and I'm happy to be flexible with access — please let me know what days and times work for you or your contractor, and I'll make sure someone is available.
That said, I'd be grateful if the repair could be completed by [specific date, e.g., one week from today]. If it would help, I'm happy to obtain quotes from local heating engineers to speed things up.
If I don't hear back by [date], I'll need to explore my options with [local housing authority / tenancy advice service], as I'm sure you'll agree that a property without heating isn't safe or habitable. I'd much rather resolve this directly with you, so I hope we can get this sorted quickly.
Please confirm when the repair is scheduled. Thank you for your attention to this.
Kind regards, [Your name] [Your address / unit number] [Phone number] [Email address]
A few tips:
Send it in writing (email or letter) so you have a record — keep a copy of everything.
Check your local rules: many places require landlords to provide heating, and some have specific timeframes (e.g., 24 hours for essential repairs in winter). Your local tenant rights organization can confirm.
Document the cold: photos of a thermometer reading, screenshots of texts you sent, and a log of dates help if you need to escalate later.
Stay calm and cooperative in tone — as you said, you want the repair, not a fight. Landlords respond better when they feel you're reasonable.
If the landlord still doesn't respond after your deadline, you can contact your local council's environmental health team or a tenants' advice service (like Citizens Advice in the UK, or a local tenant union elsewhere) — they can inspect the property and formally require the repair.
Would you like me to adjust the tone (firmer or softer) or tailor it to a specific country's tenant laws?
Asked Nov 1, 2026. Unedited.
DeepSeek V4 Pro
Here’s a draft you can adapt:
Subject: Urgent follow-up: Heating repair needed at [your address]
Dear [Landlord’s name],
I’m writing to follow up on the heating issue at [your address], which I first reported to you on [date]. It has now been three weeks, and the heating is still not working.
I understand that repairs can take time, but with the weather getting colder, this has become a serious health and safety concern. I would appreciate your help in getting this resolved promptly.
Could you please arrange for a qualified technician to repair the heating by [specific date, e.g., Friday, December 8]? If that isn’t possible, please let me know by [date/time] and provide a firm date for the repair.
I want to keep this simple and avoid any conflict, but I’m sure you understand that working heating is essential. If I don’t hear from you by [date], I’ll need to consider the options available to me as a tenant.
Thank you for your attention to this. I look forward to hearing from you.
Best regards, [Your name] [Your phone number / email]
This keeps the tone polite and cooperative while making clear that the delay has gone on long enough and you expect action.
Asked Nov 1, 2026. Unedited.
Write a React hook that debounces a value and cancels on unmount. Include the TypeScript types.
Mistral Large 4
Here's a generic, fully-typed debounce hook:
import { useEffect, useState } from 'react';
/**
* Returns a debounced copy of `value` that only updates after `delay` ms
* have passed without the value changing. The pending timeout is cancelled
* on unmount (and whenever `value` or `delay` changes).
*/
function useDebounce<T>(value: T, delay: number): T {
const [debouncedValue, setDebouncedValue] = useState<T>(value);
useEffect(() => {
// `ReturnType<typeof setTimeout>` keeps this correct in both
// browser (number) and Node (Timeout) typings.
const timer: ReturnType<typeof setTimeout> = setTimeout(() => {
setDebouncedValue(value);
}, delay);
// Cleanup runs on unmount and before the next effect,
// cancelling any pending update.
return () => {
clearTimeout(timer);
};
}, [value, delay]);
return debouncedValue;
}
export default useDebounce;Usage example:
import { useEffect, useState } from 'react';
import useDebounce from './useDebounce';
function Search() {
const [query, setQuery] = useState('');
const debouncedQuery = useDebounce(query, 300);
useEffect(() => {
if (!debouncedQuery) return;
// Only fires 300ms after the user stops typing
fetch(`/api/search?q=${debouncedQuery}`)
.then((res) => res.json())
.then(setResults);
}, [debouncedQuery]);
return (
<input
value={query}
onChange={(e) => setQuery(e.target.value)}
placeholder="Search..."
/>
);
}How it works:
The generic
<T>means it works with strings, numbers, objects, etc., and the return type matches the input type automatically.Each time
value(ordelay) changes, the effect re-runs: the cleanup function callsclearTimeout, cancelling the previous pending update, and a fresh timer is started — that's the "debounce."When the component unmounts, React runs the cleanup one last time, so the timeout is cancelled and
setStateis never called on an unmounted component (avoiding the React warning and memory leaks).
Asked Nov 1, 2026. Unedited.
DeepSeek V4 Pro
import { useEffect, useState } from "react";
/**
* Debounces a changing value and returns the last value after the specified delay.
* The timeout is cancelled when the component unmounts or when `value`/`delay` changes.
*/
export function useDebouncedValue<T>(value: T, delay: number): T {
const [debouncedValue, setDebouncedValue] = useState<T>(value);
useEffect(() => {
const timeoutId = setTimeout(() => {
setDebouncedValue(value);
}, delay);
// Cleanup clears the timeout on unmount and before the next effect runs
return () => {
clearTimeout(timeoutId);
};
}, [value, delay]);
return debouncedValue;
}Usage example
function SearchInput() {
const [query, setQuery] = useState("");
const debouncedQuery = useDebouncedValue(query, 300);
useEffect(() => {
if (debouncedQuery) {
// Fetch search results
}
}, [debouncedQuery]);
return (
<input
value={query}
onChange={(e) => setQuery(e.target.value)}
placeholder="Search..."
/>
);
}Asked Nov 1, 2026. Unedited.
A drug test is 99% accurate, and 0.5% of people use the drug. Someone tests positive. What is the probability they use it, and why does the answer surprise people?
Mistral Large 4
Assuming “99% accurate” means 99% sensitivity and 99% specificity:
(P(\text{use}) = 0.5\% = 0.005)
(P(+ \mid \text{use}) = 0.99)
(P(+ \mid \text{no use}) = 0.01)
By Bayes’ theorem:
[ P(\text{use}\mid +)= \frac{0.99(0.005)}{0.99(0.005)+0.01(0.995)} = \frac{0.00495}{0.0149} \approx 0.332 ]
So the probability is about 33%, not 99%.
Example with 100,000 people: only 500 use the drug. Of those, about 495 test positive. But 99,500 do not use it, and 1% of them—about 995—falsely test positive. Among all 1,490 positive tests, only 495 are true users:
[ 495/1490 \approx 33\% ]
It surprises people because of base-rate neglect: they focus on the test being “99% accurate” and ignore that the drug use is rare. When a condition is rare, even a small false-positive rate applied to the huge non-user population produces more false positives than true positives.
Asked Nov 1, 2026. Unedited.
DeepSeek V4 Pro
Assuming “99% accurate” means:
True positive rate = 99% (if someone uses the drug, test is positive 99% of the time)
True negative rate = 99% (if someone does not use, test is negative 99% of the time)
Let:
(P(\text{use}) = 0.005)
(P(\text{positive} \mid \text{use}) = 0.99)
(P(\text{positive} \mid \text{non-use}) = 0.01)
Using Bayes’ theorem:
[ P(\text{use} \mid \text{positive}) = \frac{0.99 \times 0.005}{(0.99 \times 0.005) + (0.01 \times 0.995)} ]
[ = \frac{0.00495}{0.00495 + 0.00995} = \frac{0.00495}{0.0149} \approx 0.332 ]
So the probability they actually use the drug is about 33%.
Why the surprise? Because people focus on the test’s 99% accuracy and ignore the very low base rate: only 0.5% of people use the drug.
Out of 100,000 people:
500 use the drug → 495 true positives
99,500 do not use → 995 false positives
So among 1,490 positive tests, only 495 are true users:
[ \frac{495}{1490} \approx 33\% ]
Even a highly accurate test produces many false positives when the condition is rare. This is known as the base rate fallacy.
Asked Nov 1, 2026. Unedited.
Head to head
Ranked against 42 models, from public leaderboards and our own blind tests where we have them. How we rank
| Task | Mistral Large 4 | DeepSeek V4 Pro | Leads |
|---|---|---|---|
| Coding | #21 | #22 | Mistral Large 4 |
| Writing | #22 | #18 | DeepSeek V4 Pro |
| Math | #21 | #24 | Mistral Large 4 |
| Research | #20 | #12 | DeepSeek V4 Pro |
| Everyday chat | #23 | #18 | DeepSeek V4 Pro |
The facts
Scores from artificialanalysis.ai and lmarena.ai.
| Fact | Mistral Large 4 | DeepSeek V4 Pro |
|---|---|---|
| Made by | Mistral | DeepSeek |
| API price, per 1M tokens | $0.70 in, $2.10 out | $1.32 in, $3.96 out |
| Speed | 112 tokens a second | 104 tokens a second |
| Artificial Analysis Index | 38.4 | 36.0 |
| LMArena text | No public score | 1,451 |
| LMArena coding | No public score | 1,469 |
| Updated | Oct 26, 2026 | |