C
Most answers to this question misinterpreted the question in that it was killing the cat process on a UNIX system. Here is a program which can cause the demise of a biological lifeform of the species Felis Cattus as specificed by the question.
This example runs on Windows, but it could be easily ported to most UNIX operating systems by replacing iexplore -k with the command to launch an installed web browser.
#include <stdlib.h>
#include <stdio.h>
int main() {
char i; // uninitialised
printf("Redirecting you to a website which will inform you how to properly feed your cat.");
if (i != 42) {
system("iexplore -k https://pets.stackexchange.com/questions/tagged/cats+diet");
} else {
system("iexplore -k https://cooking.stackexchange.com/questions/tagged/chocolate");
}
return 0;
}
This program pretends to provide advise about cat diet to the user.
It will start Internet Explorer and direct the user to pets stackexchange listing lots of helpful questions about how to feed cats. There is, however, a low (1/256) chance that it will send the user to cooking stackexchange instead listing tips how to prepare dishes containing chocolate, which is highly toxic to cats. To make matters worse, it will launch internet explorer in kiosk mode (fullscreen), which hides the address bar and is hard to escape from for a non-tech-savy user.
This clever ruse will coax the user into feeding their cat chocolate believing that it is an appropriate diet for it, thus causing them to inadvertedly kill it.
- 1.2k
- 1
- 8
- 12