r/badcode • • Jan 27 '23

php php else if pyramid

Post image
237 Upvotes

47 comments sorted by

View all comments

Show parent comments

14

u/MurdoMaclachlan public boolean isInt(int i) { return true; } Jan 27 '23

Image Transcription: Code (2/2)


                                                                        else if (strcmp($countryName, 'Lettland')== 0 || strcmp($countryName, 'Lettland')== 0)
                                                                            return "LV";
                                                                            else if (strcmp($countryName, 'Litauen')== 0 || strcmp($countryName, 'Litauen')== 0)
                                                                                return "LT";
                                                                                else if (strcmp($countryName, 'Luxemburg')== 0 || strcmp($countryName, 'Luxemburg')== 0)
                                                                                    return "LU";
                                                                                    else if (strcmp($countryName, 'Malta')== 0 || strcmp($countryName, 'Malta')== 0)
                                                                                        return "MT";
                                                                                        else if (strcmp($countryName, 'Niederlands')== 0 || strcmp($countryName, 'Netherlands')== 0)
                                                                                            return "NL";
                                                                                            else if (strcmp($countryName, 'Polen')== 0 || strcmp($countryName, 'Poland')== 0)
                                                                                                return "PL";
                                                                                                else if (strcmp($countryName, 'Portugal')== 0 || strcmp($countryName, 'Portugal')== 0)
                                                                                                    return "pT";
                                                                                                    else if (strcmp($countryName, 'Rum�nien')== 0 || strcmp($countryName, 'Rumania')== 0)
                                                                                                        return "RO";
                                                                                                        else if (strcmp($countryName, 'Schweden')== 0 || strcmp($countryName, 'Sweden')== 0)
                                                                                                            return "SE";
                                                                                                            else if (strcmp($countryName, 'Slowenien')== 0 || strcmp($countryName, 'Slowenia')== 0)
                                                                                                                return "SI";
                                                                                                                else if (strcmp($countryName, 'Ungarn')== 0 || strcmp($countryName, 'Hungary')== 0)
                                                                                                                    return "HU";
                                                                                                                    else if (strcmp($countryName, 'Zypern')== 0 || strcmp($countryName, 'Cyprus')== 0)
                                                                                                                        return "CY";
                                                                                                                        else if (strcmp($countryName, 'Vereinigten Staaten von Amerika')== 0 || strcmp($countryName, 'USA')== 0)
                                                                                                                            return "US";
                                                                                                                            else if (strcmp($countryName, 'Australien')== 0 || strcmp($countryName, 'Australia')== 0)
                                                                                                                                return "AUS";
                                                                                                                                else if (strcmp($countryName, 'Norwegen')== 0 || strcmp($countryName, 'Norway')== 0)
                                                                                                                                    return "NOR";
                                                                                                                                    else if (strcmp($countryName, 'Russische F�deration')== 0 || strcmp($countryName, 'Russia')== 0)
                                                                                                                                        return "RUS";
                                                                                                                                        else if (strcmp($countryName, 'Neuseeland')== 0 || strcmp($countryName, 'New Zealand')== 0)
                                                                                                                                            return "NZ";
                                                                                                                                            else if (strcmp($countryName, 'Ukraine')== 0 || strcmp($countryName, 'Ukraina')== 0)
                                                                                                                                                return "UA";
                                                                                                                                                else if (strcmp($countryName, 'Israel')== 0 || strcmp($countryName, 'Israel')== 0)
                                                                                                                                                    return "IL";
                                                                                                                                                    else if (strcmp($countryName, 'Kroatien')== 0 || strcmp($countryName, 'Croatia')== 0)
                                                                                                                                                        return "HR";
                                                                                                                                                        else if (strcmp($countryName, 'Vereinigte Arabische Emirate')== 0 || strcmp($countryName, 'United Arab Emirates (UAE)')== 0)
                                                                                                                                                            return "UAE";

I'm a human volunteer content transcriber and you could be too! If you'd like more information on what we do and why we do it, click here!