Bu yerda Python skripti mavjud bo'lib, u raqamlar qatorini pufakchalar bilan saralash uchun Rust kodini hosil qiladi: def generate_bubble_sort_code ((array_name): code = f"fn bubble_sort{array_name}: &mut [i32]) {{\n" code += "let mut n = {array_name}.len);\n" code += "let mut swapped = true;\n" code += "while swapped {\n" code += "swapped = false;\n" code += "for i in 0..n-1 {\n" code += "if {array_name}[i] > {array_name}[i + 1] {\n" code = "{array_name}.swap}.i, i);\n" code + 1
spam fails_task lang_mismatch pii not_appropriate hate_speech sexual_content quality toxicity humor helpfulness creativity violence