C# (Visual C# Interactive Compiler), 46 bytes
n=>Enumerable.Range(1,n).Sum(x=>n%x<1?x:0)^n*2
Returns 0 if perfect, otherwise returns a positive number. I don't know if outputting different types of integers are allowed in place of two distinct truthy and falsy values, and couldn't find any discussion on meta about it. If this is invalid, I will remove it.
C# (Visual C# Interactive Compiler) , (削除) 49 (削除ここまで) 47 bytes
n=>Enumerable.Range(1,n).Sum(x=>n%x<1?x:0)==n*2
C# (Visual C# Interactive Compiler), (削除) 49 (削除ここまで) 47 bytes
n=>Enumerable.Range(1,n).Sum(x=>n%x<1?x:0)==n*2
C# (Visual C# Interactive Compiler), 46 bytes
n=>Enumerable.Range(1,n).Sum(x=>n%x<1?x:0)^n*2
Returns 0 if perfect, otherwise returns a positive number. I don't know if outputting different types of integers are allowed in place of two distinct truthy and falsy values, and couldn't find any discussion on meta about it. If this is invalid, I will remove it.
C# (Visual C# Interactive Compiler) , (削除) 49 (削除ここまで) 47 bytes
n=>Enumerable.Range(1,n).Sum(x=>n%x<1?x:0)==n*2
C# (Visual C# Interactive Compiler), 49(削除) 49 (削除ここまで) 47 bytes
n=>Enumerable.Range(1,n).Sum(x=>n%x<1?n/x:0)==n*2
C# (Visual C# Interactive Compiler), 49 bytes
n=>Enumerable.Range(1,n).Sum(x=>n%x<1?n/x:0)==n*2
C# (Visual C# Interactive Compiler), (削除) 49 (削除ここまで) 47 bytes
n=>Enumerable.Range(1,n).Sum(x=>n%x<1?x:0)==n*2
C# (Visual C# Interactive Compiler), 49 bytes
n=>Enumerable.Range(1,n).Sum(x=>n%x<1?n/x:0)==n*2