Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
ss
Language:
Ada
Assembly
Bash
C#
C++ (gcc)
C++ (clang)
C++ (vc++)
C (gcc)
C (clang)
C (vc)
Client Side
Clojure
Common Lisp
D
Elixir
Erlang
F#
Fortran
Go
Haskell
Java
Javascript
Kotlin
Lua
MySql
Node.js
Ocaml
Octave
Objective-C
Oracle
Pascal
Perl
Php
PostgreSQL
Prolog
Python
Python 3
R
Rust
Ruby
Scala
Scheme
Sql Server
Swift
Tcl
Visual Basic
Layout:
Vertical
Horizontal
Program p1(input,output); Const N=10; Var x:array[1..10] of real; i,j,k,p:integer; MA,b:real; Begin For i:=1 to N do read(x[i]); MA:=abs(x[1]+x[2]); k:=1; p:=2; for i:=1 to N-1 do for j:=i+1 to N do begin b:=abs(x[i]+x[j]); if b > MA then begin MA:=b; k:=i; p:=j end end; write('k=',k,'p=',p) End.
Show compiler warnings
[
+
]
Show input
edit mode
|
history
|
discussion